Usage Note 35545: How to selectively add borders in the ODS RTF destination
Prior to SAS® 9.2, the control over grid lines in the ODS RTF destination is available on a table basis through the style attributes RULES= and FRAME=. With the introduction in SAS 9.2 of new style elements BORDER<location>COLOR and BORDER<location>WIDTH, where location=BOTTOM, TOP, RIGHT, or LEFT, the control of borders has moved inside the tables.
These new style attributes are listed in the "Table of General Style Attributes" located
here.
The sample code on the Full Code tab shows sample PROC REPORT syntax to place a single vertical line between two columns in the ODS RTF destination.
Operating System and Release Information
| SAS System | Base SAS | z/OS | 9.2 TS1M0 | |
| Microsoft® Windows® for 64-Bit Itanium-based Systems | 9.2 TS1M0 | |
| Microsoft Windows Server 2003 Datacenter 64-bit Edition | 9.2 TS1M0 | |
| Microsoft Windows Server 2003 Enterprise 64-bit Edition | 9.2 TS1M0 | |
| Microsoft Windows XP 64-bit Edition | 9.2 TS1M0 | |
| Microsoft® Windows® for x64 | 9.2 TS1M0 | |
| Microsoft Windows Server 2003 Datacenter Edition | 9.2 TS1M0 | |
| Microsoft Windows Server 2003 Enterprise Edition | 9.2 TS1M0 | |
| Microsoft Windows Server 2003 Standard Edition | 9.2 TS1M0 | |
| Microsoft Windows XP Professional | 9.2 TS1M0 | |
| Windows Vista | 9.2 TS1M0 | |
| 64-bit Enabled AIX | 9.2 TS1M0 | |
| 64-bit Enabled HP-UX | 9.2 TS1M0 | |
| 64-bit Enabled Solaris | 9.2 TS1M0 | |
| HP-UX IPF | 9.2 TS1M0 | |
| Linux | 9.2 TS1M0 | |
| Linux for x64 | 9.2 TS1M0 | |
| OpenVMS on HP Integrity | 9.2 TS1M0 | |
| Solaris for x64 | 9.2 TS1M0 | |
*
For software releases that are not yet generally available, the Fixed
Release is the software release in which the problem is planned to be
fixed.
The sample code uses two new style attributes, BORDERRIGHTCOLOR and BORDERRIGHTWIDTH, to add a vertical line between the MSRP and INVOICE columns. This code runs in SAS 9.2 and later.
/* SASDOCPRINTER is a style supplied by SAS that sets FRAME=HSIDES. */
ods rtf file="selective_gridlines.rtf" style=sasdocprinter;
proc report nowd missing data=sashelp.cars(obs=20);
col make model msrp invoice;
define make / order;
define model / order;
define msrp / style(column)={borderrightcolor=green borderrightwidth=3pt};
run;
ods _all_ close;
Prior to SAS® 9.2, the RULES= and FRAME= style attributes were the best way to control grid lines unless raw RTF code was inserted. New style attributes enable more control over borders.
| Date Modified: | 2009-04-29 09:53:07 |
| Date Created: | 2009-04-13 21:46:10 |