Help using Base SAS procedures

Print output onto the same page

Reply
N/A
Posts: 0

Print output onto the same page

Hi. I'd like to know how to have print output come to the same page.

If I run the code below, I get the output on two separate pages. Is there an option that will allow for these to show up one after the other on the same page?

Thank you.

title 'Input Values';
proc print data=inputs noobs width=full;
format InputX InputY InputZ 10.3;
run;

title 'Measured Values';
proc print data=measured noobs width=full;
format X Y Z 10.3;
run;
SAS Super FREQ
Posts: 8,869

Re: Print output onto the same page

Posted in reply to deleted_user
Hi:
What is your destination of choice? For RTF and PDF, your choices are to use the STARTPAGE=NO option.

cynthia
[pre]
ods listing close;
ods pdf file='myoutfile.pdf' startpage=no;
ods rtf file='myoutfile.rtf' startpage=no;

title 'Input Values';
proc print data=inputs noobs width=full;
format InputX InputY InputZ 10.3;
run;

title 'Measured Values';
proc print data=measured noobs width=full;
format X Y Z 10.3;
run;
ods _all_ close;
[/pre]
N/A
Posts: 0

Re: Print output onto the same page

Posted in reply to Cynthia_sas
Thanks Cynthia.

I'm actually just outputting to the 'Output' window in my SAS application.

Do you know if there is an option for the 'Output' window?

John Message was edited by: JohnI
SAS Super FREQ
Posts: 8,869

Re: Print output onto the same page

Posted in reply to deleted_user
Hi:
Not as easily. You could try something like the FORMDLIM option,
http://support.sas.com/documentation/cdl/en/lrdict/62618/HTML/default/a000279106.htm
and, as described here
http://support.sas.com/kb/22/205.html

If you use PROC TABULATE, the CONDENSE option will put multiple logical pages onto a physical page. Or you could switch to ODS HTML, which will only show a horizontal rule or divider under each output (instead of page breaks).

I don't know many folks who worry about how the reports look in the Output window anymore -- most of my students use the Output window to "desk check" their results and then turn off the Output window (ODS LISTING CLOSESmiley Wink in order to send their results to ODS HTML, ODS RTF or ODS PDF.

cynthia
Valued Guide
Posts: 2,177

Re: Print output onto the same page

Posted in reply to deleted_user
John,
the output window of SAS has useful options in the tools menu..Under
/tools
/ . options
/ . . output
: on the "Display" tab, just uncheck that "page mode" setting

you'll get an indication of the line break that takes only one line.

PeterC
N/A
Posts: 0

Re: Print output onto the same page

Thanks Peter and Cynthia.

Peter's suggestion is fine since I'm only looking to make it convenient to view simulation input and the measurement while testing various scenarios. Sorry, I guess I didn't pose the problem very well.

On my version (8.2 on Windows) the way to change the Page Mode is:

/Tools
/. Options
/.. Editor...

Then select 'Browse Option' from the pull down
Then change the 'PAGE' option from Yes to No.

Thanks again, John
Ask a Question
Discussion stats
  • 5 replies
  • 978 views
  • 0 likes
  • 3 in conversation