SAS Office Analytics, SAS Add-In for Microsoft Office, and other integrations

TAGSET EXCEL XP New workbook

Reply
N/A
Posts: 0

TAGSET EXCEL XP New workbook

Just upgraded to 9.2. All works fine. But when I use excelxp tagsets to create multiple sheet workbooks sas generates one workbook for each sheet.

Does anyone have solution for this problem?

Code used:

ods tagsets.excelxp file=book.xls style=statdoc;
ods tagsets.excelxp options( sheet_name='Sheet A' sheet_interval='proc');
proc tabulate;
ods tagsets.excelxp options( sheet_name='Sheet B' sheet_interval='proc');
proc tabulate;
ods tagsets.excelxp close;
SAS Super FREQ
Posts: 8,719

Re: TAGSET EXCEL XP New workbook

HI,
That is very strange. When I run this program:
[pre]
ods tagsets.excelxp file='mywb.xls' style=statdoc;
ods tagsets.excelxp options(sheet_name='Lucy' sheet_interval='proc');
proc tabulate data=sashelp.class;
class age sex;
var height;
table sex,age,
height*(min mean max);
run;

ods tagsets.excelxp options(sheet_name='Ricky' sheet_interval='proc');
proc tabulate data=sashelp.class;
class height sex;
var age;
table sex,height,
age*(min mean max);
run;

ods tagsets.excelxp close;
[/pre]

using SAS 9.2, I get one workbook (mywb.xls) with two worksheets. I suggest that you check your SAS log for errors and, if there are no errors in the LOG, if your code still continues to give you a workbook for each procedure, then you should consider contacting SAS Tech Support for more help.

cynthia
N/A
Posts: 0

Re: TAGSET EXCEL XP New workbook

Hello

Thanks for your response.

I have played around with the NEWFILE option. And the following code seems to have resolve my problem.

ods html close;
ods html newfile=bygroup;

/Anders
SAS Super FREQ
Posts: 8,719

Re: TAGSET EXCEL XP New workbook

Oh, I must have misread your original posting. I thought you wanted only ONE workbook using ODS TAGSETS.EXCELXP. I missed the need for multiple files for every BYGROUP using ODS HTML.

Glad you got it worked out!
cynthia
Ask a Question
Discussion stats
  • 3 replies
  • 233 views
  • 0 likes
  • 2 in conversation