Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 DTS ActiveX Script task and DB Connections

Author  Topic 

Marktur
Starting Member

1 Post

Posted - 2006-03-22 : 11:20:50
I have inherited a DTS that has a single ActiveX Scriot task in it. The first part is a connection to a database. Rather than have the connection in the Active X task, I want to have it reference an OLE connection that is in the DTS. The reason for this is because the connection details are entered via dynamic properties from another database. This allows me to change a passwordwithout ever going into the DTS package. Any ideas how I reference either the connection object, or dynamic properties from withing the ActiveX task?

Any help greatly appreciated!

Cheers, Mark

The code I would like to replace with a reference as indicated above:


'**********************************************************************
' Visual Basic ActiveX Script
'************************************************************************
Function Main()
set blahblahConn= CreateObject("ADODB.Connection")
blahblahConn.Open = "Provider=SQLOLEDB.1;Data Source=thesource; " & _
"Initial Catalog=blahblah;user id = 'theuserid';password = 'thepassword'"
etc
etc
etc
********************************************************************
   

- Advertisement -