The SAS Output Delivery System and reporting techniques

ods page break issue

Accepted Solution Solved
Reply
Contributor
Posts: 66
Accepted Solution

ods page break issue

Below is my code, my purpose is to print  data and text "aaaaaaaaaaaaaaaaa" in one page and "bbbbbbbbbbbbbbbbbbbbbbbbb' in another page.  How can I do it?  I do not know which option should I add between the two ods rtf text.

Thanks.

 

 

ods rtf file="C:\XXXXXXX\Desktop\111.rtf";
ods escapechar="^";
proc report data=sashelp.cars (obs=10);
run;
ods rtf text="aaaaaaaaaaaaaaaa";
ods rtf text="bbbbbbbbbbbbbbbbbbbb";
ods rtf close;


Accepted Solutions
Solution
‎02-16-2017 07:04 AM
Regular Contributor
Posts: 217

Re: ods page break issue

Hi, try to include ods startpage=now; 

HTH. 

ods rtf file="C:\XXXXXXX\Desktop\111.rtf";
ods escapechar="^";
proc report data=sashelp.cars (obs=10);
run;
ods rtf text="aaaaaaaaaaaaaaaa";
ods startpage=now;
ods rtf text="bbbbbbbbbbbbbbbbbbbb";
ods rtf close;

 

View solution in original post


All Replies
Solution
‎02-16-2017 07:04 AM
Regular Contributor
Posts: 217

Re: ods page break issue

Hi, try to include ods startpage=now; 

HTH. 

ods rtf file="C:\XXXXXXX\Desktop\111.rtf";
ods escapechar="^";
proc report data=sashelp.cars (obs=10);
run;
ods rtf text="aaaaaaaaaaaaaaaa";
ods startpage=now;
ods rtf text="bbbbbbbbbbbbbbbbbbbb";
ods rtf close;

 

Contributor
Posts: 66

Re: ods page break issue

Thanks. I tried and it works well.

Super User
Posts: 17,840

Re: ods page break issue

If I recall correctly, the text statement is similar to title in that a proc has to run before it's outputted to the RTF file. 

Contributor
Posts: 66

Re: ods page break issue

There are some difference. If there is no startpage=now. The content of ods text will be in the same page as the last output. 

☑ This topic is SOLVED.

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

Discussion stats
  • 4 replies
  • 218 views
  • 0 likes
  • 3 in conversation