dbTalk Databases Forums  

Newbie iin VB programming please help!

microsoft.public.sqlserver.dts microsoft.public.sqlserver.dts


Discuss Newbie iin VB programming please help! in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Ajay Garg
 
Posts: n/a

Default Newbie iin VB programming please help! - 12-07-2003 , 11:46 AM






I am trying to access a DTS package on a sql server and get this error
messgae .....What could be going wrong?


Private Sub Form_Load()
Dim pkg As DTS.package
pkg.LoadFromRepository "[17433136281[Windows 95/98]]", "msdb", "sa",
"", "", "", "test", DTSReposFlag_UseTrustedConnection
pkg.WriteCompletionStatusToNTEventLog = False
pkg.LogFileName = "c:\dts\error\northwindolapunleashed.txt"
pkg.FailOnError = False
pkg.PackagePriorityClass = DTSPriorityClass_Normal
pkg.MaxConcurrentSteps = 8
pkg.LineageOptions = DTSLineage_AddLineageVariables +
DTSLineage_WriteToReposIfAvailable
pkg.UseTransaction = True
pkg.TransactionIsolationLevel = DTSIsoLevel_ReadCommitted

End Sub

Object vaiable or Block variable not set...


I thinjk this is the line that is giving me problem...but what is
wriong I am no able tofigureour\t...




pkg.LoadFromRepository "[17433136281[Windows 95/98]]", "msdb", "sa",
"", "", "", "test", DTSReposFlag_UseTrustedConnection




Do we give the name of the sql server in a special type of way?

Reply With Quote
  #2  
Old   
Sue Hoegemeier
 
Posts: n/a

Default Re: Newbie iin VB programming please help! - 12-08-2003 , 06:51 AM






Try declaring the pkg variable with:
Dim pkg As New DTS.Package
You should probably be cleaning up at the end when you are
done with something like:
pkg.UnInitialize
Set pkg = Nothing

-Sue

On 7 Dec 2003 09:46:34 -0800, ajayz90 (AT) hotmail (DOT) com (Ajay
Garg) wrote:

Quote:
I am trying to access a DTS package on a sql server and get this error
messgae .....What could be going wrong?


Private Sub Form_Load()
Dim pkg As DTS.package
pkg.LoadFromRepository "[17433136281[Windows 95/98]]", "msdb", "sa",
"", "", "", "test", DTSReposFlag_UseTrustedConnection
pkg.WriteCompletionStatusToNTEventLog = False
pkg.LogFileName = "c:\dts\error\northwindolapunleashed.txt"
pkg.FailOnError = False
pkg.PackagePriorityClass = DTSPriorityClass_Normal
pkg.MaxConcurrentSteps = 8
pkg.LineageOptions = DTSLineage_AddLineageVariables +
DTSLineage_WriteToReposIfAvailable
pkg.UseTransaction = True
pkg.TransactionIsolationLevel = DTSIsoLevel_ReadCommitted

End Sub

Object vaiable or Block variable not set...


I thinjk this is the line that is giving me problem...but what is
wriong I am no able tofigureour\t...




pkg.LoadFromRepository "[17433136281[Windows 95/98]]", "msdb", "sa",
"", "", "", "test", DTSReposFlag_UseTrustedConnection




Do we give the name of the sql server in a special type of way?


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.