![]() |
.XLS to .CSV Macro Conversion
My company has recently upgraded us from Windows2000/Excel2000 to
WindowsXP/Excel2003. I am having a problem converting .xls to .csv that uses ";" semicolon as the separator. The Regional Setting for List Separator is ";" semicolon. My old code is this: Awb.SaveAs Filename:=Left(Awb.Name, Len(Awb.Name) - 4), FileFormat:=xlCSV This issue seems to be specific to the code I am using - I have tried to manually save an xls file to csv and it worked fine. Is there a way to fix my code so that the .csv uses ";" as the separator ? Thank you in advance. |
.XLS to .CSV Macro Conversion
Maybe you could write your own exporting program that would behave exactly the
way you want: Here are three sites that you could steal some code from: Earl Kiosterud's Text Write program: www.smokeylake.com/excel (or directly: http://www.smokeylake.com/excel/text_write_program.htm) Chip Pearson's: http://www.cpearson.com/excel/imptext.htm J.E. McGimpsey's: http://www.mcgimpsey.com/excel/textfiles.html (or maybe you could build your own formula and copy|paste into Notepad.) ============== Take a look at Earl's program. I bet it does what you want. carl wrote: My company has recently upgraded us from Windows2000/Excel2000 to WindowsXP/Excel2003. I am having a problem converting .xls to .csv that uses ";" semicolon as the separator. The Regional Setting for List Separator is ";" semicolon. My old code is this: Awb.SaveAs Filename:=Left(Awb.Name, Len(Awb.Name) - 4), FileFormat:=xlCSV This issue seems to be specific to the code I am using - I have tried to manually save an xls file to csv and it worked fine. Is there a way to fix my code so that the .csv uses ";" as the separator ? Thank you in advance. -- Dave Peterson |
.XLS to .CSV Macro Conversion
Thanks Dave. You have been very helpful now and in the past.
This sounds like a glitch in the excel 2003 ? "Dave Peterson" wrote: Maybe you could write your own exporting program that would behave exactly the way you want: Here are three sites that you could steal some code from: Earl Kiosterud's Text Write program: www.smokeylake.com/excel (or directly: http://www.smokeylake.com/excel/text_write_program.htm) Chip Pearson's: http://www.cpearson.com/excel/imptext.htm J.E. McGimpsey's: http://www.mcgimpsey.com/excel/textfiles.html (or maybe you could build your own formula and copy|paste into Notepad.) ============== Take a look at Earl's program. I bet it does what you want. carl wrote: My company has recently upgraded us from Windows2000/Excel2000 to WindowsXP/Excel2003. I am having a problem converting .xls to .csv that uses ";" semicolon as the separator. The Regional Setting for List Separator is ";" semicolon. My old code is this: Awb.SaveAs Filename:=Left(Awb.Name, Len(Awb.Name) - 4), FileFormat:=xlCSV This issue seems to be specific to the code I am using - I have tried to manually save an xls file to csv and it worked fine. Is there a way to fix my code so that the .csv uses ";" as the separator ? Thank you in advance. -- Dave Peterson |
.XLS to .CSV Macro Conversion
I remember earlier versions of excel behaving the same way. Am I
misremembering? But I'd say it was more VBA being USA centric. (It's only a bug if you don't use the comma as your delimiter <vbg.) carl wrote: Thanks Dave. You have been very helpful now and in the past. This sounds like a glitch in the excel 2003 ? "Dave Peterson" wrote: Maybe you could write your own exporting program that would behave exactly the way you want: Here are three sites that you could steal some code from: Earl Kiosterud's Text Write program: www.smokeylake.com/excel (or directly: http://www.smokeylake.com/excel/text_write_program.htm) Chip Pearson's: http://www.cpearson.com/excel/imptext.htm J.E. McGimpsey's: http://www.mcgimpsey.com/excel/textfiles.html (or maybe you could build your own formula and copy|paste into Notepad.) ============== Take a look at Earl's program. I bet it does what you want. carl wrote: My company has recently upgraded us from Windows2000/Excel2000 to WindowsXP/Excel2003. I am having a problem converting .xls to .csv that uses ";" semicolon as the separator. The Regional Setting for List Separator is ";" semicolon. My old code is this: Awb.SaveAs Filename:=Left(Awb.Name, Len(Awb.Name) - 4), FileFormat:=xlCSV This issue seems to be specific to the code I am using - I have tried to manually save an xls file to csv and it worked fine. Is there a way to fix my code so that the .csv uses ";" as the separator ? Thank you in advance. -- Dave Peterson -- Dave Peterson |
All times are GMT +1. The time now is 09:21 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com