![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
I'm using VB 6 with SQL 2000. I have a DTS package that works correctly in SQL Enterprise Manager. Now I have to incorporate it into a VB 6 |
|
I'm using the following code: ' Declare SQL DTS Objects Dim oPKG As DTS.Package, oStep As DTS.Step Set oPKG = New DTS.Package Dim sServer As String, sUsername As String, sPassword As String Dim sPackageName As String, sMessage As String Dim lErr As Long, sSource As String, sDesc As String, FileLoc As String FileLoc = FilePath ' Set Parameter Values sServer = "Server_Leadpool" sUsername = "sa" sPassword = "sa" sPackageName = "dtsProcess_DVSPledgeFile" ' Load Package oPKG.LoadFromSQLServer sServer, sUsername, sPassword, DTSSQLStgFlag_UseTrustedConnection, , , , sPackageName oPKG.GlobalVariables("FileLocation").Value = FileLoc ' Set Exec on Main Thread For Each oStep In oPKG.Steps oStep.ExecuteInMainThread = True Next ' Execute oPKG.Execute oPKG.UnInitialize Set oStep = Nothing Set oPKG = Nothing The process runs without an error that I know of but at the same time nothing is being done. The DTS package is supposed to populate two tables. |
|
How can I check to see if the package is being triggered to run and insert some error checking. Thank you very much |
![]() |
| Thread Tools | |
| Display Modes | |
| |