Auto Create CSV from a xlsx Template... possible??

James Gordon

New member
Joined
Apr 5, 2013
Messages
1
Reaction score
0
Points
0
Hi

I'm looking to populate the data of an existing .csv file from a .xlsx file

The simple procedure of saving as .csv isn't adequate. I'm looking to populate an online database with specific information of some 10'000 products so it's a large data input task. I have created a Template in excel which makes it very quick, easy and simple to use for people with limited PC knowledge. Obviously the headers needed for the CSV files are not ones most would recognise. I can save as CSV and it uploads perfectly but that's a manual process which I can't trust staff to carry out.

Is there some way of linking the CSV file to the xlsx file? I'm assuming that wouldn't work as a CSV file will not retain the relevant code that points it to the XLSX file??

Can something be set-up that when you save the XLSX it automatically saves as .CSV as well?

Your help would be appriciated.

James
 
Yes, you can save as CSV file and then resave in the original Excel file format you had.

Something like this:
wbkDest.SaveAs Filename:=strFilePath & "SomeFileName.csv", FileFormat:=xlCSV, CreateBackup:=False
wbkDest.SaveAs Filename:=strWorkbookName, FileFormat:=52, CreateBackup:=False

Will you need to prompt the user for a directory where to save the file? Or will that be hard-coded?

More info in this at http://www.rondebruin.nl/saveas.htm
 
Back
Top