Marino_CRO
New Member
- Joined
- Jun 17, 2012
- Messages
- 3
Hi,
Please help me !
Few years ago there was some discussion on this forum (http://www.mrexcel.com/forum/showth...V-semicolon-delimited&highlight=csv+semicolon ) about the problem that I have but I hope that my problem deserves a new thread because it is slightly more specific.
I am trying to save excel file as csv semicolon delimited file. While I was doing it manualy (File->Saveas->CSV(commaDelimited)) it worked fine, but with macro it gives me file with commas (without semicolons)!?
My macro (main part) is:
Activeworkbook.SaveAs Filename:=..., Fileformat:=xlCSV, Local:=True
I set Windows (7) Regional Settings List Separator to ";" (as it was suggested in some Excel forums) but it still wont not work properly
Then I asked for advice in another Excel forum (http://chandoo.org/forums/topic/i-need-help-with-macro-to-save-excel-file-to-csv-semicolon-delimited ) and try what they have suggested to me: ('...In Excel 2010, under File-Options-Advanced, deselect “Use System Separators” and enter a “,” for Decimal Separator, and a space for Thousands Separator...and remove this Local:=True...') but i still get csv with commas instead of semicolons.
I also tried to use 'xlCSVMSDOS' and 'xlCSVWINDOWS' but the result is the same, csv with commas and not with semicolons.
However, as I mentioned before, when I try to do it manually (without macro) it works fine, and when I use macro(which is same as manual action File->SaveAs->CSV(comma delimited)) it gives me different type of separator!?
Only difference is that when I use File->SaveAs->CSV(comma delimited) Excel gives me notification "Filename...may contain features that are not compatible with CSV (comma delimited). Do you want to keep the workbook in this format ?" When I record macro for that action (File->SaveAS...) this notification is not in VBA and I don't know a code for it ? Maybe that's the reason why I can't get csv with semicolons ?
I read somewhere that this is a some kind of bug in Excel ?
Otherwise, use Excel 2010 and Windows 7.
Thanks in advance for any suggestions !
Please help me !
Few years ago there was some discussion on this forum (http://www.mrexcel.com/forum/showth...V-semicolon-delimited&highlight=csv+semicolon ) about the problem that I have but I hope that my problem deserves a new thread because it is slightly more specific.
I am trying to save excel file as csv semicolon delimited file. While I was doing it manualy (File->Saveas->CSV(commaDelimited)) it worked fine, but with macro it gives me file with commas (without semicolons)!?
My macro (main part) is:
Activeworkbook.SaveAs Filename:=..., Fileformat:=xlCSV, Local:=True
I set Windows (7) Regional Settings List Separator to ";" (as it was suggested in some Excel forums) but it still wont not work properly
Then I asked for advice in another Excel forum (http://chandoo.org/forums/topic/i-need-help-with-macro-to-save-excel-file-to-csv-semicolon-delimited ) and try what they have suggested to me: ('...In Excel 2010, under File-Options-Advanced, deselect “Use System Separators” and enter a “,” for Decimal Separator, and a space for Thousands Separator...and remove this Local:=True...') but i still get csv with commas instead of semicolons.
I also tried to use 'xlCSVMSDOS' and 'xlCSVWINDOWS' but the result is the same, csv with commas and not with semicolons.
However, as I mentioned before, when I try to do it manually (without macro) it works fine, and when I use macro(which is same as manual action File->SaveAs->CSV(comma delimited)) it gives me different type of separator!?
Only difference is that when I use File->SaveAs->CSV(comma delimited) Excel gives me notification "Filename...may contain features that are not compatible with CSV (comma delimited). Do you want to keep the workbook in this format ?" When I record macro for that action (File->SaveAS...) this notification is not in VBA and I don't know a code for it ? Maybe that's the reason why I can't get csv with semicolons ?
I read somewhere that this is a some kind of bug in Excel ?
Otherwise, use Excel 2010 and Windows 7.
Thanks in advance for any suggestions !