The SAS Output Delivery System and reporting techniques

Footnote placement in tagsets.rtf

Accepted Solution Solved
Reply
Contributor
Posts: 23
Accepted Solution

Footnote placement in tagsets.rtf

I tried TAGSETS.RTF this morning for the first time, just for the heck of it, with a simple program that has a 3-page PROC PRINT and a 1-page PROC FREQ.

The biggest difference I noticed from traditional ODS RTF output was the placement of the footnotes on "short" pages. With ODS RTF, the footnotes always wind up at the bottom (since Word is managing them), which is what I expect and want.

With TAGSETS.RTF, however, when I have output that only partially fills the page, such as my PROC FREQ or the last page of my PROC PRINT, the footnote is placed directly after the procedure output, rather than at the bottom of the page. To me, this is odd and somewhat annoying.

I realize that with TAGSETS.RTF, the footnote information is within the body of the document rather than in the Microsoft Word header and footer, but is there any way to tell SAS to always put it at the very bottom of the page, where I want it?


Accepted Solutions
Solution
‎11-30-2012 05:53 PM
SAS Super FREQ
Posts: 8,819

Re: Footnote placement in tagsets.rtf

Hi:

  Found it! Try the TAGSETS.RTF_SAMPLE destination. I was teaching and didn't have a chance to pursue this, but I did finally discover that the wonderful ODS developers have already gotten requests for this behavior. And, they've written a version of TAGSETS.RTF that puts the SAS titles and footers into the header and footer areas of the RTF document.

  They wrote about the RTF_SAMPLE tagset a while ago in this paper (updated version):

http://support.sas.com/rnd/base/ods/odsrtf/067-31-updated.pdf and I found that TAGSETS.RTF_SAMPLE was included in SAS 9.3 template item store. So, you don't have to download the code if you have SAS 9.3.

cynthia

ods tagsets.rtf_sample file='c:\temp\something_new.rtf'

    options(doc='Help');

title 'the title';

footnote 'the footnote';

proc report data=sashelp.class(obs=1) nowd;

run;

title; footnote;

ods _all_ close;

View solution in original post


All Replies
Occasional Contributor
Posts: 10

Re: Footnote placement in tagsets.rtf

Hi,

I have the same "problem" ( see https://communities.sas.com/message/144593#144593 ) and thought that I could solve it like described here

http://www.phuse.eu/download.aspx?type=cms&docID=4197

But I cannot modify my tagset due to a SAS bug (I have SAS 9.3 M0), perhaps you can do it.

I think that one must modify the pagebreak event where the rtf control code for header and footer is defined. Maybe you can do it Smiley Happy If yes, let me know...

New Contributor
Posts: 3

Re: Footnote placement in tagsets.rtf

but the footnote can't apply  j=r "@R/RTF'\qr Page these attributes, and the color is not grey, like normal, but black

SAS Super FREQ
Posts: 8,819

Re: Footnote placement in tagsets.rtf

HI:

  It is not a good idea to add your comment in the middle of a year old posting. It would be better to start a new post and refer to this post in your description. I was about to report a problem with the forum system because I did not initially see you post here in the middle of all the other postings from a year ago.
     

  The color is NOT gray. Your footnote default color is BLACK. Normally, the "original" RTF -- ODS RTF -- put the footnote from SAS into the "footer area" of the Word document. If you go into Edit Footer mode, you will see that although the footnote text looks gray/grey in the document, when you are in Edit Footer mode, the Footnote is really in black font color.
      

  I do not know what you mean when you say, "but the footnote can't apply  j=r "@R/RTF'\qr" because with J=R, you should not need to use RTF control strings like \qr. If you run the attached code, you will see that, no matter what destination I use, the colors in the footnote lines are slightly muted versions of the colors that you would see if you went into Edit Footer mode. This explains why the normally black footnote looks gray/grey. When you use TAGSETS.RTF, the footnote is NOT put into the footer section of the Word document. The SAS Footnote is put into the BODY of the document, so there is no muting of the color.
    

Cynthia

   

ods rtf file='c:\temp\examp_orig.rtf' ;

ods tagsets.rtf file='c:\temp\examp_new.rtf' ;

ods tagsets.rtf_sample file='c:\temp\examp_samp.rtf';

   

proc print data=sashelp.shoes(obs=50);

title 'This is the Title';

footnote j=r color=cyan 'This is the Footnote 1';

footnote2 j=l color=purple 'This is Footnote 2';

footnote3 j=c color=green 'This is Footnote 3';

  var region product sales;

run;

ods _all_ close;

Solution
‎11-30-2012 05:53 PM
SAS Super FREQ
Posts: 8,819

Re: Footnote placement in tagsets.rtf

Hi:

  Found it! Try the TAGSETS.RTF_SAMPLE destination. I was teaching and didn't have a chance to pursue this, but I did finally discover that the wonderful ODS developers have already gotten requests for this behavior. And, they've written a version of TAGSETS.RTF that puts the SAS titles and footers into the header and footer areas of the RTF document.

  They wrote about the RTF_SAMPLE tagset a while ago in this paper (updated version):

http://support.sas.com/rnd/base/ods/odsrtf/067-31-updated.pdf and I found that TAGSETS.RTF_SAMPLE was included in SAS 9.3 template item store. So, you don't have to download the code if you have SAS 9.3.

cynthia

ods tagsets.rtf_sample file='c:\temp\something_new.rtf'

    options(doc='Help');

title 'the title';

footnote 'the footnote';

proc report data=sashelp.class(obs=1) nowd;

run;

title; footnote;

ods _all_ close;

Contributor
Posts: 23

Re: Footnote placement in tagsets.rtf

That does the trick -- thanks!

Mike

Occasional Contributor
Posts: 10

Re: Footnote placement in tagsets.rtf

But the continued tag at the end of a table which has page breaks is now gone Smiley Sad

🔒 This topic is solved and locked.

Need further help from the community? Please ask a new question.

Discussion stats
  • 6 replies
  • 2868 views
  • 3 likes
  • 4 in conversation