The SAS Output Delivery System and reporting techniques

Retaining Options in ExcelXP Tagset

Reply
Super Contributor
Posts: 358

Retaining Options in ExcelXP Tagset

Hi All:

I'm using the ExcelXP tagset to create a number of reports in a single SAS program. Each Excel tab created has a number of options that are specified with regard to the appearance of the report (zoom, orientation, etc.)

Is there a way that I can set these options once and not bother on each successive report - ie: the second report would "inherit" the same options as the first?

This would make maintenance much easier since I would only have to change the reporting option once, and not for each report produced.

I know that I could use macro variables, but I would rather not take that approach.

Any suggestions?
SAS Super FREQ
Posts: 8,743

Re: Retaining Options in ExcelXP Tagset

Hi!
First, you have to make sure you have the latest copy of the ExcelXP tagset, by downloading it from this web site: http://support.sas.com/rnd/base/topics/odsmarkup/
running the code (without ANY changes) and updating your sasuser.templat template store.

Then, submit an ExcelXP job with this option:
ods tagsets.excelxp file='x.xls' options(doc='help');
..
Look in the SAS log for info on using and creating an INI file to use with the ExcelXP tagset....it saves all your zoom, orientation, other options in an easy to use and easy to reference file.

cynthia
Super Contributor
Posts: 358

Re: Retaining Options in ExcelXP Tagset

Thanks Cynthia.

While I'm on the topic, I use a %include to include the tagset in my code when I run it. Is there an easy way to keep the tagset from listing as code in my log? Can I just code 'option nosource' before the include and then turn the source back on afterwards?

(I know I could save it and just point to the saved version, but I just do it this way by habit.)
SAS Super FREQ
Posts: 8,743

Re: Retaining Options in ExcelXP Tagset

Hi!
Well, I think if you do
options nosource nosource2 nomprint;

that should just about get rid of it all.
cynthia

PS: I think you can throw a nonotes in there, too. But I find it troublesome to always do a %include. So I have a perm template store where I write the updated tagsets and styles and then I just do:
[pre]
ods path mytemp.templat(update)
sashelp.tmplmst(read);
[/pre]
in order to save myself having to submit the template code each time. You may have noticed that the excelxp tagset is quite lengthy!
Ask a Question
Discussion stats
  • 3 replies
  • 137 views
  • 0 likes
  • 2 in conversation