The SAS Output Delivery System and reporting techniques

ODS RTF TEXT on the first page

Reply
Occasional Contributor
Posts: 7

ODS RTF TEXT on the first page

Hello,

 

I got a problem with "ods rtf text". I want a text (using ods rtf text) on the first page of my output. Her is an example:

 

 

ODS ESCAPECHAR ='~';
ods rtf startpage=no notoc_data;
title1 j=l 'Project' j=r 'page ~{PAGEOF}'; 
title2 j=l 'Text on first page';

	ods rtf startpage=now;
	ods rtf text="Text on first page"; 

ods rtf startpage=now;

title2 j=l 'Analysis'; 
title3 j=l '1. Origin'; 

	PROC TABULATE data=sashelp.cars;
		class Origin;  
		table Origin,(N pctn='%'*F=4.1); 
	RUN;  

ods rtf startpage=now;

title3 j=l '2. DriveTrain'; 
ods rtf text="~S={outputwidth=100% just=l} {\tc\b\f3\fs0\cf8 2. DriveTrain}"; 

	ods rtf text="It's working on each other page, but not the first"; 

ods rtf close;

 

There is always the table immediately after my text. I want the text on the first and the table on the second page.

 

Hope you can help me.

 

Martin

 

Esteemed Advisor
Esteemed Advisor
Posts: 6,726

Re: ODS RTF TEXT on the first page

I would not use ods text for that.  Put the text you want to apper on the first page in a dataset, then proc report that data, you can supress labels by putting a space and drop borders and get the text you want on page 1.  

Occasional Contributor
Posts: 7

Re: ODS RTF TEXT on the first page

Sounds good. But I have to use ods rtf text. Is it possible to create an invisible table/report?

Esteemed Advisor
Esteemed Advisor
Posts: 6,726

Re: ODS RTF TEXT on the first page

Ah, that old chestnut "But I have to use"...

 

Yes, you can create reports which don;t look like reports, set borders to none for instance, set labels to " ".

Post a Question
Discussion Stats
  • 3 replies
  • 170 views
  • 0 likes
  • 2 in conversation