danishgambit
Member
OE 10.2b
excel 2003.
Afternoon 'talkers,
I know there are plenty of posts on this forum about using excel and progress, but I can't find a solution to the problem I'm having. I feel sure it's relatively commonplace so either I've missed it, or it's so straight forward that no-one has had a problem with it.
I've dumped data to 3 csv files that I want to open in 3 separate tabs on an excel file.
I can do 1 file easily enough, using
I can open a spreadsheet with multiple tabs and loop round each worksheet changing the name etc, but I can't workout how to open a csv file for each tab.
Any ideas ?
TIA,
DG.
excel 2003.
Afternoon 'talkers,
I know there are plenty of posts on this forum about using excel and progress, but I can't find a solution to the problem I'm having. I feel sure it's relatively commonplace so either I've missed it, or it's so straight forward that no-one has had a problem with it.
I've dumped data to 3 csv files that I want to open in 3 separate tabs on an excel file.
I can do 1 file easily enough, using
Code:
DEFINE VARIABLE chExcelApplication AS COM-HANDLE NO-UNDO.
DEFINE VARIABLE chWorkBook AS COM-HANDLE NO-UNDO.
DEFINE VARIABLE chWorkSheet AS COM-HANDLE NO-UNDO.
CREATE "Excel.Application" chExcelApplication.
chExcelApplication:WindowState = 1.
ASSIGN chExcelApplication:VISIBLE = false.
chExcelApplication:Workbooks:Open(vFileName).
chWorkBook = chExcelApplication:WorkBooks:ITEM(1).
chExcelApplication:SheetsInNewWorkBook = 1.
chWorkSheet = chExcelApplication:Sheets:ITEM(1).
.....
I can open a spreadsheet with multiple tabs and loop round each worksheet changing the name etc, but I can't workout how to open a csv file for each tab.
Any ideas ?
TIA,
DG.