Here's what I'm wondering about -- related, but going further with the discussion. In the SAS title statement, you can use #byvar and #byval, etc with by group processing. ODS PROCLABEL does not currently support #byvar and #byval, but -if- it did, then you could kill 2 birds etc, etc, by allowing something like this:
[pre]
ods html ....;
ods tagsets.excelxp ...;
options nobyline;
ODS PROCLABEL "#byvar1 = #byval1";
proc whatever data=wombat;
by koala eucalyptus;
run;
ods _all_ close;
[/pre]
if ods html was using contents=, then every by group could use ODS PROCLABEL automatically without doing macro things to get the TOC label the way you wanted.
if excelxp was making multiple worksheets, then ODS PROCLABEL could indicate the string to be picked up by the tagset.
I know that Eric has done something similar in a tagset revision to answer a different question (for me, offline), but this possibility ODS PROCLABEL ...or a new ODS PROCBYLABEL might simplify things in making a one place to specify what you want using the #byval and #byvar that already exists and that folks know how to use.
Of course, changing a tagset is my favorite morning activity -- but it's not a solution for everybody -- and implementing the #byvar etc functionality via ODS PROCBYLABEL or ODS PROCLABEL -- would make it easier for folks new to SAS and ODS to do something slick with a much lower learning curve. If #byvar and #byval are put -someplace- so the title statement can get to them, why can't they be pumped into someplace in memory that persists beyond the life of the title statement???
just curious,
cynthia