The SAS Output Delivery System and reporting techniques

Attempt to set Headery and Footery in RTF and/or tagsets.RTF

Reply
Contributor
Posts: 22

Attempt to set Headery and Footery in RTF and/or tagsets.RTF

I've successfully used the RTF destination and sent section data to it to set the Header and Footer margin in the RTF output file, as follows:

ods RTF sectiondata='\headery720\footery576';

this corresponds to a 0.5 in header margin and a 0.4 in footer margin.

But when I try to do the same with the tagsets.RTF destination, via the following syntax:

ods tagsets.RTF options(SECT=''\headery720\footery576');

the end result is a line in the RTF file that sets the header and footer margin correctly ... but then it is immediately followed by a line generated by the tagsets, that resets the header and footer margin to 1440 (i.e. 1 in which is the top and bottom margin settings).

I note that in the tagsets.RTF the following "offending" language is probably the culprit:

put $sect_data;
put NL;
put "\headery" TOPMARGIN "\footery" BOTTOMMARGIN;
put "\marglsxn" LEFTMARGIN "\margrsxn" RIGHTMARGIN;
put "\margtsxn" TOPMARGIN "\margbsxn" BOTTOMMARGIN;
set $pagecols PAGE_COLUMNS /if exists( PAGE_COLUMNS);
put NL;

which as I guessed using the TOPMARGIN AND BOTTOMMARGIN values to 'reset' the header and footer margins.

I really like some of the features of the tagsets.RTF destination over those of the RTF destination --- and as such would really like to use it ... but w/o being able to correctly set the header and footer margins I can't change yet.

Any workarounds/solutions?
Super User
Posts: 9,681

Re: Attempt to set Headery and Footery in RTF and/or tagsets.RTF

Hi.
There are several System Options can adjust the margin of RTF file.


[pre]
options topmargin=4 cm bottommargin=4 cm leftmargin=0 cm rightmargin=0 cm nodate nonumber center ;
[/pre]


Ksharp
Contributor
Posts: 22

Re: Attempt to set Headery and Footery in RTF and/or tagsets.RTF

Those do not impact the header and footer margins ... which are the distance away from the top and bottom (respectively) that the running headers and footers in an RTF (and/or MSWord) documents run. The main text of the document's distance from the edge of the paper is controlled by the options you list. As far as I know there isn't an equivalent options setting in SAS that directly relates to the RTF/MSWord document header/footer margin.

That's why I'm used the direct SECTIONDATA "option" in the ODS RTF statement (and attempted to use the SECT= option in the ODS tagset.RTF statement) to pass along a direct string to the RTF DOCUMENT that would set the header/footer margins.
Super User
Posts: 9,681

Re: Attempt to set Headery and Footery in RTF and/or tagsets.RTF

Hi.
I am afraid that you need to change Microsoft WORD 's options.

Start->Open Word->File->Page Setup->Format-> 'Set' Page_brow and' Page_foot to 0 cm.

Ksharp
SAS Super FREQ
Posts: 8,743

Re: Attempt to set Headery and Footery in RTF and/or tagsets.RTF

Hi:
I'd suggest you open a track with Tech Support. If your HEADERY and FOOTERY are being reset by control strings from the tagset template, then Tech Support could either work with you on a control string method to set the HEADERY and FOOTERY or they could work with the TAGSETS.RTF developer to find out whether there is an updated tagset template that does not have this behavior.

To open a track with Tech Support, fill out the form at this link:
http://support.sas.com/ctx/supportform/createForm

cynthia
Ask a Question
Discussion stats
  • 4 replies
  • 484 views
  • 0 likes
  • 3 in conversation