Posted by SimplySuzy on 10/05/06 17:24
Help
I am trying to open a text file that I am naming dynamically through
global variables in a dts package. When I print the file name to the
screen, it is correct. When I use the dts package itself with this file
name it opens only when I click on the elipsis, click on the file and
click open.
I have tried this with and without the text extension.
I am trying a workaround by setting the properties of the text file in
code and opening it this way but I don't have the correct syntax.
Can anyone help?
Set oConn = DTSGlobalVariables.Parent.Connections("Mail Import")
oConn.DataSource = sFileName
oConn.Properties.FileType = "ANSI"
oConn.DataSource.Properties.RowDelimiter = "{CR}{LF}"
oConn.DataSource.Properties.TextQualifier = "<none>"
oConn.DataSource.Properties.FirstRowHasColumnNames = 1
oConn.DataSource.Properties.ColumnDelimiter = 1
thanks
Suzy
Navigation:
[Reply to this message]
|