Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

DTS Import text file into Global Variable

Status
Not open for further replies.

Chance1234

IS-IT--Management
Jul 25, 2001
7,871
US
I have a text file source, which i want to import into a global variable which i can then later retrieve as a recordset.

I know how to do this if it was a database source, but cant see how to do it with a text source


with regards

Chance,



Filmmaker, gentleman and pearls before swine fan

 
In the ActiveX--
'**********************************************************************
' Visual Basic ActiveX Script
'************************************************************************

Function Main()

Dim oPKG
Dim cn
Set oPKG = DTSGlobalVariables.Parent
Set cn = oPKG.Connections("Text File (Source)") cn.DataSource = DTSGlobalVariables("FilePath").Value
Main = DTSTaskExecResult_Success
End Function


You should have a on success connection pointing to a Text File (Source) and
GlobalVariable as FilePath
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top