Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have been using this archive for a few months now and have found them
wonderfully useful. I have a very strange problem though... when I define a text file and delimit it in an Excel macro it amends some dates. In the .txt file the dates are all in the month of December 01/12/2004; 02/12/2004 etc... when I use the macro below it reverses the dates in the cell to 12/01/2004 etc... Sub myFile = Application.GetOpenFilename("Text,*.txt") Workbooks.OpenText Filename:=myFile, DataType:=xlDelimited, Comma:=True End Sub If I do not have the first line of code but instead have the location of an actual file this problem does not exist. e.g. Sub Workbooks.OpenText Filename:="S:\myFile.TXT", DataType:=xlDelimited, Comma:=True End Sub Any ideas would severely be appreciated as this is the first part of a macro that I run for 15-20 different file names a week. Solomon |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Importing Comma delimited file | Excel Discussion (Misc queries) | |||
How to produce comma-delimited and quoted text file from Excel? | Excel Discussion (Misc queries) | |||
How can I save a file as a comma-delimited text file in Excel? | Excel Discussion (Misc queries) | |||
how to save a file as ASCII: expanded comma delimited text (.exp). | Excel Discussion (Misc queries) | |||
I have a Comma delimited text file how do I import in to excel an. | Excel Discussion (Misc queries) |