The SAS Output Delivery System and reporting techniques

ods tagsets.htmlpanel event=row_panel(start) ;

Reply
Frequent Contributor
Posts: 115

ods tagsets.htmlpanel event=row_panel(start) ;

Hi All,

I am using the tagset.htmlpanel to crreate a dashboard report in Information Delivery Portal.

Is there a way I can control the allignment of the tagset. For instance, say I wanted to right align everything that falls within the tagset.

Thanks.
SAS Super FREQ
Posts: 8,862

Re: ods tagsets.htmlpanel event=row_panel(start) ;

Hi:
I'm confused and it depends.

Here's what I'm confused about: you say you want to control "the alignment of the tagset" and that you want to "right align everythign that falls within the tagset" -- I don't know what that means. The tagset template is simply building CSS Style properties and HTML tags -- that's all. So "everything that falls within the tagset" are the procedures or by groups or graphs that you have surrounded with your ODS TAGSETS.HTMLPANEL statements.

For example, if you look at the HTML file created with ODS TAGSETS.HTMLPANEL, you will see alignment information like this (in the CLASS= attribute, which points back to the alignment style properties at the end of the <STYLE> section):
[pre]
<tr>
<th class="r RowHeader" scope="row"> 1</th>
<td class="l Data">Alfred</td>
<td class="l Data">M</td>
<td class="r Data">14</td>
<td class="r Data">69.0</td>
<td class="r Data">112.5</td>
</tr>
[/pre]

where the class="r RowHeader" or class="l Data" are determined for every cell in the table. Would this be the alignment you want to change??? So that all the class="l Data" were changed to class="r Data"??? You can right-align individual cell values by using style= overrides in PROC REPORT, PROC PRINT and PROC TABULATE or by altering the style template that you are using for your code or by altering the tagset template (HTMLPANEL) that you are using for your code.

or, there is an overall alignment that is set for a whole table. Generally, this overall alignment is done with <DIV> tags, as shown below:
[pre]
<a name="IDX"></a>
<table class="SysTitleAndFooterContainer" width="100%" cellspacing="1" cellpadding="1" rules="none" frame="void" border="0" summary="Page Layout">
<tr>
<td class="c SystemTitle">The SAS System</td>
</tr>
</table><br>
<div align="center">

<table cellpadding="0">
<tr>
<td>
<div align="center">
[/pre]

Would you want the <div align="center"> to change to <div align="right"> -- in order to change the alignment of the whole table?? Or would you want the class="c SystemTitle" to change to class="r SystemTitle"???? You can change the justification of the SystemTitle in regular ODS HTML, by using the j= option on the title statement:
[pre]
title j=r "This is My Title";
[/pre]

If you want to change the <DIV> tag, then your only solution may be to edit the tagset template for ODS HTMLPANEL -- unless there's a sub-option that impacts what goes into the <DIV> tag. I believe that the System Option NOCENTER -- might work, but you want right-aligned and NOCENTER should end up left-aligning the output???
[pre]
options nocenter;
[/pre]

So, whether you can right-align "everything" depends on what you mean by "everything". What procedures are you using and what exactly do you mean by "right align everything"??

cynthia
Frequent Contributor
Posts: 115

Re: ods tagsets.htmlpanel event=row_panel(start) ;

Let me try and simplyfy,

I have the output of a proc report enclosed with ods tagsets.htmlpanel.

Is there a way i can specify, to that ods tagset, a specific alignment(left, center, right, etc...)
SAS Super FREQ
Posts: 8,862

Re: ods tagsets.htmlpanel event=row_panel(start) ;

Hi:
Alignment of WHAT?? Of the TITLE?? Of the WHOLE table??? Of individual cells within the table??

cynthia
Frequent Contributor
Posts: 115

Re: ods tagsets.htmlpanel event=row_panel(start) ;

Of the objects within the div created by the tagset.

I am using it to create a report similar to this http://robslink.com/SAS/democd22/tele.htm
SAS Super FREQ
Posts: 8,862

Re: ods tagsets.htmlpanel event=row_panel(start) ;

That example was NOT done with TAGSETS.HTMLPANEL. It was done with GREPLAY and ANNOTATE, as described here:
http://robslink.com/SAS/democd22/tele_info.htm
and the program is here:
http://robslink.com/SAS/democd22/tele.sas

The "objects" in HTMLPANEL are either graphs or tabular objects. Whether or not you can right-align them depends on what part of the object you are talking about. However, since the code for that example is available is there some issue with just using the code example at the above web site??

cynthia
Ask a Question
Discussion stats
  • 5 replies
  • 372 views
  • 0 likes
  • 2 in conversation