Opening CSV in excel from VB
How about importing the data into a new worksheet? Then you'll be in
control of how EXCEL interprets the file, even if the file does have
the CSV extension. For example, something like:
Workbooks.Add
With ActiveSheet.QueryTables.Add(Connection:= _
"TEXT;C:\Documents and Settings\Administrator\My Documents\My
Spreadsheets\Temp\Test.csv" _
, Destination:=Range("A1"))
.AdjustColumnWidth = True
.TextFileParseType = xlDelimited
.TextFileSemicolonDelimiter = True
.Refresh BackgroundQuery:=False
End With
|