I'm new to CSS styling in SAS so bear with me. I'm trying to get a double outside border and solid inside border using the following code, which is edited in Notepad++ and then called into a SAS ODS output using cssstyle= in an ODS RTF statement:
.table { border: medium double black; color: #000000; font-family: 'Arial', 'Arial'; font-size: 10pt; font-style: normal; font-weight: normal;
}
.proctitle{ color: #000000; font-family: Arial, 'Albany AMT', Arial; font-size: x-small; font-style: normal; font-weight: bold;
}
.systemtitle{ font-family: Arial, 'Albany AMT', Arial; font-size: large; font-weight: 14pt; color: black;
}
.header, .rowheader, .footer, .rowfooter{ color: black; font-size: 10pt; font-family: Arial, 'Albany AMT', Arial; background-color: #ffffff; font-weight: bold; text-align: center; vertical-align: middle; padding: 10px;
}
.data{ font-size: 10pt; font-family: Arial, 'Albany AMT', Arial; background-color: #ffffff; text-align: center; vertical-align: middle; padding: 10px; border: medium solid black;
}
However, this creates a the first table shown below. I'd like to get it to look like the second table shown below. Stack Exchange users suggested I come here as they have not found an answer. I appreciate any insight!
I am sorry, you must be mistaken. CSS (Cascading Style Sheet) is something associated with Web Pages, its not really a SAS issue. What are you attempting to do (i.e. what output format, what code are you using etc.)? Is this something generated by the SAS system? Maybe look here:
http://support.sas.com/rnd/base/ods/templateFAQ/Template_csstyle.html
What I have pasted above is the full code in a text editor, saved as a .css file (in this case, named TESTFOX.css). I'm using ODS RTF as shown below:
DATA TEST; INPUT CAR $10. YEAR; DATALINES; FORD 1995 HONDA 1998 CHEVY 2001 ; RUN; ODS RTF FILE="C:\USERS\DOCUMENTS\TEST.RTF" CSSSTYLE='C:\USERS\DOCUMENTS\TESTFOX.CSS'; PROC PRINT DATA=TEST NOOBS; RUN; ODS _ALL_ CLOSE;
Attached is what the table looks like. There is the double outside border, but there is no inside solid border.
Join us for SAS Innovate 2025, our biggest and most exciting global event of the year, in Orlando, FL, from May 6-9. Sign up by March 14 for just $795.
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.
Ready to level-up your skills? Choose your own adventure.