opentext

N

neia

I wrote the code below to open a txt file.
Workbooks.OpenText Filename:="C:\Meus documentos\auxilio
transporte\BS.txt", _
Origin:=xlMSDOS, StartRow:=1, DataType:=xlDelimited, TextQualifier:= _
xlDoubleQuote, ConsecutiveDelimiter:=False, Tab:=False,
Semicolon:=True, _
Comma:=False, Space:=False, Other:=False, FieldInfo:=Array(Array(1,
1), _
Array(2, 1), Array(3, 1), Array(4,4), Array(5, 4), Array(6, 1),
Array(7, 1)), _
TrailingMinusNumbers:=True

There is some problem with the data fields because some rows appears as I´d
like to see (03/mai/06 - format dd/mmm/yy) and others rows, from the same
colomn, appears: 03MAI2006 (format general).
This problem disapear if I use macro in excel 97 or if i open the text file
manually.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top