Moj kod je sledeci:
Code:
Package2Class package = new Package2Class();
Object pVarPersistStgOfHost = System.Reflection.Missing.Value;
package.LoadFromStorageFile("someDts.dts", null, null, null, "dtsPackage",ref pVarPersistStgOfHost);
foreach (GlobalVariable global in package.GlobalVariables)
{
switch (global.Name)
{
case "SourceInitialCatalog":
global.Value = DataSourceDatabase;
break;
}
}
package.Execute();
foreach (Step2 step in package.Steps)
{
int outError;
string outSource;
string outDescription;
string out1;
int out2;
string out3;
step.GetExecutionErrorInfo(out outError, out outSource, out outDescription, out out1, out out2, out out3);
}
package.UnInitialize();
package = null;
Dakle, imam dts paket sacuvan negde kao storage file. Vrlo je jednostavan - iz neke tabele treba da prebaci podatke u csv file. Jedina globalna varijabla je InitialCatalog. Medjutim, kada idem step po step, dobijam gresku "Type mismatch. Missing parameter does not have a default value". Pri tom, ja nemam nigde definisane parametre...
Imas li pojma sta bi to moglo da bude?
The important thing is not to stop questioning. Curiosity has its own reason for existing. - Albert Einstein