I keep getting a compile error on the VB.NET script saying that a declaration was expected on the 'PublicSub','sMsg','MsgBox' and 'Dts'.
The 'End Sub' is telling me it must be preceded by a matching 'Sub'.
I know nothing about the syntax from VB.NET but all I did was copy and paste your code over the code that was already there. Replacing the exsisting 'Main' function.
Holding my mouse over the SQL execute task in BIDS tells me that the task is configured to pre-compile the script, but no binary code is found. Please visit the IDE....
You need to correct your code and place a space in your 'Main' function to equal:
Public Sub Main()
This will help save some confusion for some of us non-code junkies. 🙂
Otherwise, very nice article.