I am trying to execute a DTS package I created on a SQLserver7.0 database.
I can successfully run this package on my VB, but however if try to run the
same code in ASP, I get a message saying "invalid string". How can I
resolve this issue. The environment is Websrvr on Machine1, SQLserver on
machine2 and my browser on machine3. here is the sample code I am trying to
execute..
<%
Const DTSReposFlag_Default = 0
Const DTSReposFlag_UseTrustedConnection = 256
Dim oPackage, strResult
iStatus = True
Set oPackage = Server.CreateObject("DTS.Package")
oPackage.LoadFromSQLServer "MyServer", "MyUser", "MyPswd", 0, "", "", "",
"DTS_MyPackage"
call oPackage.Execute()
Response.Write "Executing package...<BR>"
Response.Write CSTR(oPackage.Steps.Count) + "<br>"
For i = 1 To oPackage.Steps.Count
If oPackage.Steps(i).ExecutionResult = DTSStepExecResult_Failure Then
oPackage.Steps(i).GetExecutionErrorInfo (lpErrorCode)
iStatus = False
strErr = oPackage.Steps(i).Name + " in the " + oPackage.Description + "
failed.<BR>"
End If
Response.Write strResult
Next
If iStatus = True Then
strResult = oPackage.Description + " Successful<BR>"
Response.Write strResult
End If
Response.Write "Done.<BR>"
%>
Any help will be greatly appreciated. Thanks in advance.
/Phanindra Mankale
pmankale@o...