Re: parameter driven DTS -
09-30-2006
, 12:36 PM
the actual code is given below from my form: the string "newSUID" is set as
the globalvariables in the DTS package
Dim package As DTS.Package2Class
package = New DTS.Package2Class
Dim filename As String
Dim password As String
Dim packageID As String
Dim versionID As String
Dim name As String
Dim pVarPersustStgOfHost As Object
filename = "c:\New.dts"
password = ""
packageID = ""
versionID = ""
name = "New"
' assign the global variable a value here
package.GlobalVariables.Item("newSUID").Value =
"1.3.6.1.4.1.2452.6.120050221.20844.304.1416026628 "
pVarPersustStgOfHost = Nothing
package.LoadFromStorageFile(filename, _
password, packageID, versionID, _
name, pVarPersustStgOfHost)
Try
package.Execute()
Catch ex As Exception
MsgBox(ex.ToString)
Finally
package.UnInitialize()
package = Nothing
End Try
Any ideas and help pls
kesk |