View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Helmut Helmut is offline
external usenet poster
 
Posts: 111
Default save as csv cell format

Dave,
That's not it....
1 - I do a manual Save-As and select in the dialogue box the CSV and save
the file. \When opening it, the date in Column C is dd/mm/yyyy just as it was
in the xls file.
2 - I run the Macro Save-As CSV and the Column C in the CSV file becomes
mm/dd/yyyy
here is the macro I use:

fileSaveName = Application.GetSaveAsFilename("\\c:\MESSER\MESSERm myy",
fileFilter:="CSV Files (*.csv), *.csv")

'save the file

ActiveWorkbook.SaveAs Filename:= _
fileSaveName, FileFormat _
:=xlCSV, CreateBackup:=False



"Dave Peterson" wrote:

Don't verify your data in that CSV file by reopening it in Excel.

Open that CSV file in NotePad to check it out.

If you really want to reopen the CSV file in Excel, then rename it to .TXT and
then you can specify the format you need for that date field.

Helmut wrote:

I have WORKSHEET(1) with Column "C" formatted as dd/mm/yyyy
__with other values in other columns
I copy and paste_special 'values'
then
I 'saveas' the file in *CSV format and when I open the CSV file the date
format has changed to 'general' which is to be expected in CSV, but the value
has also changed to m/dd/yyyy

I need the format in the CSV file to be dd/mmm/yyyy
thanks


--

Dave Peterson