I have a long program that creates a detailed report with multiple tables. At the very top of the program I prevent page breaks with
ODS RTF STARTPAGE=NO;
I would like the tables organized so they are in multiple columns & rows across the page i.e. the page should look like:
Table 1 Table 4 Table 7
Table 2 Table 5 Table 8
Table 3 Table 6 Table 9
I tried using ODS RTF COLUMNS=3 but that only creates multiple columns, not rows, so the page looks like this:
Table 1 Table 2 Table 3
I'm using SAS 9.2 on a Windows 7 machine with MS Office 2010
Hi:
You may want to work with Tech Support on this. I do not believe that ODS RTF supports ODS LAYOUT. You might have to switch to ODS PDF and use ODS LAYOUT to arrange your tables next to each other in the way you describe. What COLUMNS= does is create multiple columns from your procedure output, but it will not necessarily align multiple tables the way you describe. Of course, you could change the order in which you arrange your procedure calls to impact the way they get created...in other words:
proc for table 1
proc for table 4
proc for table 7
proc for table 2
proc for table 5
proc for table 8
etc, etc
But the best thing for you to do is open a track with Tech Support.
cynthia
Thanks, Cynthia. I tried your suggestion of separate FREQ procedures for each table, and that did not make any difference.
The same code used to work in earlier versions of SAS; I'm currently using SAS 9.2. After some googling, it appears that in earlier versions, SAS would not insert any page breaks between procedures if ODS RTF STARTPAGE=NO was used. But in the newer versions of SAS, SAS inserts a continuous page break between procedures if ODS RTF STARTPAGE=NO is used. This may be a contributing factor. I have contacted SAS tech support about this.
And yes, it work fine if I use ODS PDF. I may have to resort to that if nothing else works.
Don't miss out on SAS Innovate - Register now for the FREE Livestream!
Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.
Learn how use the CAT functions in SAS to join values from multiple variables into a single value.
Find more tutorials on the SAS Users YouTube channel.