The only difference that I can see to my code is that I do not remove and add the Global variable ... I just pass the new value through.
As I said before >I know you've asked for ASP.NET, but in VB 6 you'll do it like this ...
So here is my code for executing ...
Dim objPackage As DTS.Package2
'Instanciate the DTS package object
Set objPackage = New DTS.Package2
'Set the server/username/password and the DTS package to be run
objPackage.LoadFromSQLServer Server, UserName, Password, DTSSQLStgFlag_Default, "", "", "", "DTS_PackageName"
objPackage.GlobalVariables("FromDate").Value = dtpFrom.Value
objPackage.GlobalVariables("ToDate").Value = dtpTo.Value
'Set object to raise an error on failure and to do eventlogs
objPackage.FailOnError = True
objPackage.WriteCompletionStatusToNTEventLog = True
'Run DTS Package
objPackage.Execute
objPackage.UnInitialize
Set objPackage = Nothing
Hope this helps ...
I was standing in the park, wondering why frisbees got bigger as they came closer... then it hit me!