-----------------------------------------------------------

New Message on BDOTNET

-----------------------------------------------------------
From: shailaja
Message 3 in Discussion

Hi, I am trying to run DTS which is stored in some folder not in SQL server. Here is 
the code snippet for the same. But I am getting COMException could not find package in 
the storage location specified though it is present. Can anybody help me to find out 
what must be going wrong? Thanks in advance. Shailaja    
[MTAThread] 
static void Main(string[] args) 
{ 
try 
{ 
Package2Class package = new Package2Class(); 
object pVarPersistStgOfHost = null; 
// if you need to load from file 
package.LoadFromStorageFile( 
"D:\\4Seasons\\4s Dynamic DTS\\4S_POS_TXT_IMPORT.dts", 
null, 
null, 
null, 
"Test Package", 
ref pVarPersistStgOfHost); 
package.Execute(); 
package.UnInitialize(); 
// force Release() on COM object 
//  
System.Runtime.InteropServices.Marshal.ReleaseComObject(package); 
package = null; 
} 
catch(System.Runtime.InteropServices.COMException e) 
{ 
Console.WriteLine("COMException {0}", e.ErrorCode.ToString() ); 
Console.WriteLine("{0}", e.Message); 
Console.WriteLine("{0}", e.Source); 
Console.WriteLine("Stack dump\n{0}\n", e.StackTrace); 
} 
catch(System.Exception e) 
{ 
Console.WriteLine("Exception"); 
Console.WriteLine("{0}", e.Message); 
Console.WriteLine("{0}", e.Source); 
Console.WriteLine("Stack dump\n{0}\n", e.StackTrace); 
} 
} // main

-----------------------------------------------------------

To stop getting this e-mail, or change how often it arrives, go to your E-mail 
Settings.
http://groups.msn.com/BDotNet/_emailsettings.msnw

Need help? If you've forgotten your password, please go to Passport Member Services.
http://groups.msn.com/_passportredir.msnw?ppmprop=help

For other questions or feedback, go to our Contact Us page.
http://groups.msn.com/contact

If you do not want to receive future e-mail from this MSN group, or if you received 
this message by mistake, please click the "Remove" link below. On the pre-addressed 
e-mail message that opens, simply click "Send". Your e-mail address will be deleted 
from this group's mailing list.
mailto:[EMAIL PROTECTED]

Reply via email to