samedi 18 avril 2015

When outputting multiple sheets using ods tagsets.ExcelXP and body=test.html it doesn't work as intended

I am outputting several tables into several worksheets in one xml type Excel spreadsheet.


The problem I am having is that out of the six worksheets I am outputting, the final four are using a body=test.html as well, to allow certain style formats to work (which only work if I use the body= command). When it runs however, the first two worksheets are output and the final four are not.


eg.



ods tagsets.excelxp file='example.xls' options(...sheet_name=sheet1...);

proc report;
run;

ods tagsets.excelxp options(...sheet_name=sheet2...);
proc tabulate;
run;

ods tagsets.excelxp body='test1.html' options(...sheet_name=sheet3...);
proc report;
run;
ods tagsets.excelxp body='test2.html' options(...sheet_name=sheet4...);
proc report;
run;
ods tagsets.excelxp body='test3.html' options(...sheet_name=sheet5...);
proc report;
run;
ods tagsets.excelxp body='test4.html' options(...sheet_name=sheet6...);
proc report;
run;

ods tagsets.excelxp close;


The first two are output fine, but the final four are not. I have tried placing the body='test.html' for each ods tagsets.excelxp line, but it doesn't work and just outputs the first sheet. I cannot skip out the ods tagsets.excelxp lines as I need different options for each sheet...is there a way to output these in the same spreadsheet? I am not allowed to use VBA or any manual interventions.


Please help! Thank you so much!


Aucun commentaire:

Enregistrer un commentaire