<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to decorate line in Proc Report? in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/How-to-decorate-line-in-Proc-Report/m-p/182992#M46604</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi:&lt;/P&gt;&lt;P&gt;&amp;nbsp; Can you point me to the place in the documentation where you found this syntax for CALL DEFINE???&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-size: 10pt;"&gt;&lt;STRONG&gt;&lt;SPAN style="font-family: Courier New;"&gt;call&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier New;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier New;"&gt;define&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier New;"&gt;(&lt;SPAN style="color: #ff0000;"&gt;_lines_&lt;SPAN style="color: #000000;"&gt;,&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier New;"&gt;'style'&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier New;"&gt;, ' ...');&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;As far as I know, this is incorrect syntax and I could not find it in the documentation.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also, if you are using ODS, then your HEADLINE and HEADSKIP are entirely unnecessary and ignored by ODS destinations.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Last, how you achieve a background color of yellow will be the same for all destinations, but how to achieve underlining depends on what version of SAS you have (9.1.3, 9.2, 9.3, etc) and on your destination. Since you don't show your destination, or give your version of SAS, it's hard to help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also, although you showed code that used SASHELP.CARS (thanks for that), you didn't post working code (your code should show errors in the log) and you did not show ALL your code -- what is your ODS DESTINATION of choice? HTML, RTF, PDF???&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks, cynthia&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PS...your COMPUTE BEFORE _PAGE_ is creating 1 box at the top of each table on each "page" -- for some destinations, that box can only be 1 color. 1 box=1 background. Each LINE statement can have different text, but ALL the line statements in your COMPUTE block are going into 1 box. Some destinations might allow you to have a different background for each "line statement", but generally, this turns out not looking the way you think it will. And, as I said, you didn't mention your destination of interest.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 22 Feb 2014 15:08:47 GMT</pubDate>
    <dc:creator>Cynthia_sas</dc:creator>
    <dc:date>2014-02-22T15:08:47Z</dc:date>
    <item>
      <title>How to decorate line in Proc Report?</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-decorate-line-in-Proc-Report/m-p/182991#M46603</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear SAS Communities Members :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have attached sample code below.&lt;/P&gt;&lt;P&gt;How can I change background/font type/font size&amp;nbsp; of line # 1 (Make : Acura)&amp;nbsp; to yellow,&lt;/P&gt;&lt;P&gt;and insert a blank thin line&amp;nbsp;&amp;nbsp; and&lt;/P&gt;&lt;P&gt;change background/font type/font size of line # 3 (Type : SUV) to lightblue ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;proc report data=sashelp.cars(obs=25 keep=Make&lt;/TD&gt;&lt;TD&gt;Model&lt;/TD&gt;&lt;TD&gt;Type&lt;/TD&gt;&lt;TD&gt;Origin&lt;/TD&gt;&lt;TD&gt;DriveTrain&lt;/TD&gt;&lt;TD&gt;MSRP&lt;/TD&gt;&lt;TD&gt;Invoice&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;) nowd headline headskip&lt;/P&gt;&lt;P&gt;style(report)=[cellspacing=5 borderwidth=0 bordercolor=white]&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;style(header)=[color=Black&lt;/TD&gt;&lt;TD&gt; &lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; fontstyle=italic fontsize=4]&lt;/P&gt;&lt;P&gt;style(column)=[color=moderate brown&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; fontfamily=helvetica fontsize=4]&lt;/P&gt;&lt;P&gt;style(lines)=[color=white backgroundcolor=black&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; fontstyle=italic fontweight=bold fontsize=5]&lt;/P&gt;&lt;P&gt;style(summary)=[color=cx3e3d73 backgroundcolor=cxaeadd9&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; fontfamily=helvetica fontsize=3 textalign=r] &lt;/P&gt;&lt;P&gt;style(calldef)=[background=white]; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;Columns Make model&lt;/TD&gt;&lt;TD&gt;&lt;/TD&gt;&lt;TD&gt;Type&lt;/TD&gt;&lt;TD&gt;Origin&lt;/TD&gt;&lt;TD&gt;DriveTrain&lt;/TD&gt;&lt;TD&gt;MSRP&lt;/TD&gt;&lt;TD&gt;Invoice&lt;/TD&gt;&lt;TD&gt;&amp;nbsp; ;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt; Define make / Order Noprint;&lt;/P&gt;&lt;P&gt; Define model / 'Model'&amp;nbsp;&amp;nbsp; ;&lt;/P&gt;&lt;P&gt;&amp;nbsp; Define type / Order Noprint;&lt;/P&gt;&lt;P&gt;&amp;nbsp; Define origin / Order Noprint;&lt;/P&gt;&lt;P&gt;&amp;nbsp; Define DriveTrain / Order Noprint;&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&amp;nbsp; Define&lt;/TD&gt;&lt;TD&gt;MSRP / sum analysis ;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;&amp;nbsp; Define&lt;/TD&gt;&lt;TD&gt;invoice / sum analysis ;&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt; break after type / page skip;&lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;/TD&gt;&lt;TD&gt;compute before _page_ / left&amp;nbsp;&amp;nbsp; style=[font_weight=bold foreground=green background=yellow]; &lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;&lt;/TD&gt;&lt;TD&gt;if&amp;nbsp; make&amp;nbsp; ne ' '&amp;nbsp; then&amp;nbsp; call define(_lines_,'style', 'style=[ foreground=green background=yellow&amp;nbsp; fontstyle=italic fontsize=2 ]');&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp; line 'Make: ' Make $char.&amp;nbsp; ; &lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp; line ' ';&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt; &lt;/TD&gt;&lt;TD&gt;if Type ne ' '&amp;nbsp; then&amp;nbsp; call define(_row_,'style', 'style=[ foreground=red background=silver&amp;nbsp; fontstyle=italic fontsize=2&amp;nbsp; ]');&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt; line 'Type : ' Type&amp;nbsp; $char.; &lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt; endcomp; &lt;/P&gt;&lt;TABLE&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;run;&amp;nbsp; &lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/TD&gt;&lt;TD&gt;&lt;/TD&gt;&lt;TD&gt;&lt;/TD&gt;&lt;TD&gt;&lt;/TD&gt;&lt;TD&gt;&lt;/TD&gt;&lt;TD&gt;&lt;/TD&gt;&lt;TD&gt;&lt;/TD&gt;&lt;TD&gt;&lt;/TD&gt;&lt;TD&gt;&lt;/TD&gt;&lt;TD&gt;&lt;/TD&gt;&lt;TD&gt;&lt;/TD&gt;&lt;TD&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 22 Feb 2014 03:00:39 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-decorate-line-in-Proc-Report/m-p/182991#M46603</guid>
      <dc:creator>GPatel</dc:creator>
      <dc:date>2014-02-22T03:00:39Z</dc:date>
    </item>
    <item>
      <title>Re: How to decorate line in Proc Report?</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-decorate-line-in-Proc-Report/m-p/182992#M46604</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi:&lt;/P&gt;&lt;P&gt;&amp;nbsp; Can you point me to the place in the documentation where you found this syntax for CALL DEFINE???&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-size: 10pt;"&gt;&lt;STRONG&gt;&lt;SPAN style="font-family: Courier New;"&gt;call&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier New;"&gt; &lt;/SPAN&gt;&lt;SPAN style="font-family: Courier New;"&gt;define&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier New;"&gt;(&lt;SPAN style="color: #ff0000;"&gt;_lines_&lt;SPAN style="color: #000000;"&gt;,&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier New;"&gt;'style'&lt;/SPAN&gt;&lt;SPAN style="font-family: Courier New;"&gt;, ' ...');&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;As far as I know, this is incorrect syntax and I could not find it in the documentation.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also, if you are using ODS, then your HEADLINE and HEADSKIP are entirely unnecessary and ignored by ODS destinations.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Last, how you achieve a background color of yellow will be the same for all destinations, but how to achieve underlining depends on what version of SAS you have (9.1.3, 9.2, 9.3, etc) and on your destination. Since you don't show your destination, or give your version of SAS, it's hard to help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also, although you showed code that used SASHELP.CARS (thanks for that), you didn't post working code (your code should show errors in the log) and you did not show ALL your code -- what is your ODS DESTINATION of choice? HTML, RTF, PDF???&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks, cynthia&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;PS...your COMPUTE BEFORE _PAGE_ is creating 1 box at the top of each table on each "page" -- for some destinations, that box can only be 1 color. 1 box=1 background. Each LINE statement can have different text, but ALL the line statements in your COMPUTE block are going into 1 box. Some destinations might allow you to have a different background for each "line statement", but generally, this turns out not looking the way you think it will. And, as I said, you didn't mention your destination of interest.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 22 Feb 2014 15:08:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-decorate-line-in-Proc-Report/m-p/182992#M46604</guid>
      <dc:creator>Cynthia_sas</dc:creator>
      <dc:date>2014-02-22T15:08:47Z</dc:date>
    </item>
    <item>
      <title>Re: How to decorate line in Proc Report?</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-decorate-line-in-Proc-Report/m-p/182993#M46605</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Cynthia:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for your prompt reply and comments.&amp;nbsp; SAS code (Version SAS 9.4) updated is attached below for your review and reference.&amp;nbsp; &lt;/P&gt;&lt;P&gt;Is it possible to design report with following changes ?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;(1) For the second line, it should be ' THIN ' line with white background.&lt;/P&gt;&lt;P&gt;(2) Background of third line (which reads -: Type : Sedan) should be other than yellow. &lt;/P&gt;&lt;P&gt;(3) Font Color&amp;nbsp; for the third line should be black.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;%let ff = %str(HEIGHT=9PT Bold F=ARIAL bcolor="White" color='BLACK') ;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp; %Let Title1 =%str(Line of Business : Electronics);&lt;/P&gt;&lt;P&gt;&amp;nbsp; %Let Title2 =%str(US Export);&lt;/P&gt;&lt;P&gt;&amp;nbsp; %Let Title3 =%str(Enterprise Unit);&lt;/P&gt;&lt;P&gt;&amp;nbsp; %Let Title4 =%str(Report ID: Ele_Export_US);&lt;/P&gt;&lt;P&gt;&amp;nbsp; %Let Title5 =%str(Department : HR01AL9012) ;&lt;/P&gt;&lt;P&gt;&amp;nbsp; %Let Title6 =%str(Paid Period);&lt;/P&gt;&lt;P&gt;&amp;nbsp; %Let Title7 =%str( December 2013);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Title&amp;nbsp; Font=Arial bold height=12pt &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; J=c "&amp;amp;title1"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; J=c Font=Arial bold height=12pt&amp;nbsp; "&amp;amp;title2"&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; J=l Font=Arial bold height=10pt&amp;nbsp; "&amp;amp;title3"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; J=l Font=Arial bold height=10pt&amp;nbsp; "&amp;amp;title4"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; J=c Font=Arial bold height=9pt&amp;nbsp;&amp;nbsp; "^{newline 1}"&amp;nbsp; "&amp;amp;title5"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; J=c Font=Arial bold height=9pt&amp;nbsp;&amp;nbsp; "^{newline 1}"&amp;nbsp; "&amp;amp;title6"&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; J=c Font=Arial bold height=9pt&amp;nbsp;&amp;nbsp; "^{newline 1}"&amp;nbsp; "&amp;amp;title7";&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; FootNote ' ';&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; ODS escapechar='^';&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ODS _all_ close;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp; options orientation=landscape leftmargin="0.2cm" rightmargin="0.2cm" Device=ACTXIMG&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; topmargin="0.5cm" bottommargin="0.5cm" nodate nonumber&amp;nbsp; center&amp;nbsp;&amp;nbsp; spool printerpath="Postscript";&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp; ODS pdf file="d:\temp\Test.pdf" style=sasweb startpage=yes notoc; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp; %Let starttime=%sysfunc(datetime()); &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; Proc Report Data=sashelp.cars(obs=5 keep=Make Model Type Origin MSRP Invoice) nowd &lt;/P&gt;&lt;P&gt;&amp;nbsp; style(report)=[cellspacing=5 borderwidth=0 bordercolor=white]&lt;/P&gt;&lt;P&gt;&amp;nbsp; style(header)=[color=Black&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Fontstyle=italic Fontsize=4]&lt;/P&gt;&lt;P&gt;&amp;nbsp; style(column)=[color=moderate brown&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Fontfamily=helvetica Fontsize=4]&lt;/P&gt;&lt;P&gt;&amp;nbsp; style(lines)=[color=black backgroundcolor=black&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Fontstyle=italic Fontweight=bold Fontsize=5]&lt;/P&gt;&lt;P&gt;&amp;nbsp; style(summary)=[color=cx3e3d73 backgroundcolor=cxaeadd9&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Fontfamily=helvetica Fontsize=3 textalign=r];&lt;/P&gt;&lt;P&gt;&amp;nbsp; /* style(calldef)=[background=white]; /* Reference from SAS Guide to Report Writing&amp;nbsp; By Michele M. Burlew : Page 191 */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp; Columns Make model Type Origin MSRP Invoice&amp;nbsp; ;&lt;/P&gt;&lt;P&gt;&amp;nbsp; Define make / Order Noprint;&lt;/P&gt;&lt;P&gt;&amp;nbsp; Define model / 'Model'&amp;nbsp;&amp;nbsp; ;&lt;/P&gt;&lt;P&gt;&amp;nbsp; Define type / Order Noprint;&lt;/P&gt;&lt;P&gt;&amp;nbsp; Define origin / Order Noprint;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp; Define MSRP / sum analysis ;&lt;/P&gt;&lt;P&gt;&amp;nbsp; Define invoice / sum analysis ; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp; break after type / page skip;&lt;/P&gt;&lt;P&gt;&amp;nbsp; compute before _page_ / left&amp;nbsp;&amp;nbsp; style=[Font_weight=bold foreground=green background=yellow];&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; if&amp;nbsp; _Break_&amp;nbsp; ne ' '&amp;nbsp; then&amp;nbsp; CALL DEFINE(_COL_,'style', 'style=[ foreground=green background=yellow&amp;nbsp; Fontstyle=italic Fontsize=2 ]');&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; line 'Make: ' Make $char.&amp;nbsp; ; /* First Line */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; line ' ';&amp;nbsp;&amp;nbsp; /* Blank Line */&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; if _Break_&amp;nbsp; ne ' '&amp;nbsp;&amp;nbsp; then&amp;nbsp; CALL DEFINE(_COL_,'style', 'style=[ foreground=red background=silver&amp;nbsp; Fontstyle=italic Fontsize=2&amp;nbsp; ]');&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; line 'Type : ' Type&amp;nbsp; $char.;&amp;nbsp; /* Third Line */&lt;/P&gt;&lt;P&gt;&amp;nbsp; endcomp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp; run;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; ODS PDF Close;&lt;/P&gt;&lt;P&gt;&amp;nbsp; ODS LISTING ;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 23 Feb 2014 01:27:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-decorate-line-in-Proc-Report/m-p/182993#M46605</guid>
      <dc:creator>GPatel</dc:creator>
      <dc:date>2014-02-23T01:27:43Z</dc:date>
    </item>
    <item>
      <title>Re: How to decorate line in Proc Report?</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-decorate-line-in-Proc-Report/m-p/182994#M46606</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi:&lt;/P&gt;&lt;P&gt;&amp;nbsp; Thanks for posting an update to your code. Some points..and a code example to test your basic question of can a single cell from COMPUTE BEFORE have 2 background colors?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;1) This statement is what is making your background yellow and foreground green:&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp; compute before _page_ / left&amp;nbsp; style=[Font_weight=bold foreground=green background=yellow];&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;These 2 statements are totally being ignored:&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp; if _Break_&amp;nbsp; ne ' '&amp;nbsp;&amp;nbsp; then&amp;nbsp; CALL DEFINE(_COL_,'style', 'style=[ foreground=red background=silver&amp;nbsp; Fontstyle=italic Fontsize=2&amp;nbsp; ]');&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp; if&amp;nbsp; _Break_&amp;nbsp; ne ' '&amp;nbsp; then&amp;nbsp; CALL DEFINE(_COL_,'style', 'style=[ foreground=green background=yellow&amp;nbsp; Fontstyle=italic Fontsize=2 ]');&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; Generally, _COL_ is used to change the attributes of 1 cell. Your 2 statements are coded as though you think you have 2 different cells, but you don't. When you use the COMPUTE BEFORE _PAGE_, you are putting a gigantic cell a single cell above the whole table. And the if _BREAK_ ne ' ' test is really not testing for anything. The COMPUTE BEFORE _PAGE_ will only execute one time at the beginning of each page.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;You can prove this to yourself by changing the COMPUTE block to&lt;STRONG style="font-family: courier new,courier;"&gt;:&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp; compute before _page_ / left&amp;nbsp; style=[Font_weight=bold foreground=purple background=pink];&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;you will now see pink and purple being used instead of yellow and green and you will not see red and silver anywhere. Your CALL DEFINE just won't work.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;2) So if it is the COMPUTE block style override that is touching the LINES, then that means that this override in the PROC statement is totally being ignored&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;style(lines)=[color=black backgroundcolor=black&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Fontstyle=italic Fontweight=bold Fontsize=5]&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;and it doesn't make sense anyway for the foreground and the background to both be BLACK. STYLE(LINES) applies to the TEXT that you write, not to anything else, not to actual underlines or border lines.&amp;nbsp; So you may as well remove this override from the PROC statement. Or else take off the color= and backgroundcolor=, they are irrelevant to what you are trying to do.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;3) You said that you wanted "For the second line, it should be ' THIN ' line with white background." What second line? -- your second LINE statement is writing out 1 single space. If you underline that space, it will be with the same thickness of underline as any other underline. And what you would underline would be 1 space -- IF your destination even respected the single space for an underline. Some will, some won't. You might have to switch to a non-breaking space, and even then, I'm not sure that PDF will "respect" the underline for a non-breaking space..&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;4) then you said "Background of third line (which reads -: Type : Sedan) should be other than yellow." and "Font Color&amp;nbsp; for the third line should be black" However, as I put in my PS to the first post. -- when you have a COMPUTE BLOCK, you are making 1 single cell that spans the whole table. You can put 1 LINE statement of text in the cell. You can put 10 LINE statements of text in the cell. It is 1 cell. You can't make the background of 1 line yellow and the background of 1 line green. A single cell has a single background. The TEXT in the cell can have a different foreground color -- so the first line could have green text and the third line could have red text, but you can't have 2 different backgrounds in PDF. I believe that PDF will use the first color...so your COMPUTE BEFORE block will produce 1 cell with 1 background color. Each line can have a different foreground color, but you will NOT change it with CALL DEFINE. You will have to use ODS ESCAPECHAR style overrides, similar to what you did&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;5) You are using "relative font sizes" in your code. every time you do that, you are making ODS PDF do the work of translating from the relative numbers (used most often in HTML output) to absolute PT numbers (used most often in PDF output). It would be nicer to just specify&amp;nbsp; Fontsize=12pt or Fontsize=10pt or Fontsize=18pt in your overrides instead of making PDF do the calculations from relative to absolute. And since you use absolute numbers in your TITLE, it doesn't make sense why you use relative numbers in your report.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;6) Skip (like headline and headskip) is a "LISTING" only option. Totally ignored by ODS PDF -- unneeded here. And irrelevant...since your action on the break is to do a page break, the skip would even be ignored in LISTING.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;7) I don't see any benefit to having just a single TITLE statement. SAS allows you to have 10 TITLE statements. Why not just use them. You only seem to have 7 text strings&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;span class="lia-unicode-emoji" title=":smiling_face_with_sunglasses:"&gt;😎&lt;/span&gt; you have DEVICE=ACTXIMG -- but you do not have a SAS/GRAPH or PROC SGPLOT or a STAT procedure step. Not needed unless you have a graphics step.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;9) You have startpage=yes as an option -- this is the default. Don't know why you have this.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp; So let's take a step back from even trying to change the colors based on the MAKE and TYPE variables and just see what's possible with each destination. Here's a simple PROC REPORT where ALL we are dealing with is the COMPUTE BEFORE block and seeing how/whether/if a destination like PDF will even respect multiple background colors in a cell. Multiple foreground colors is very possible. But before you jump into the complex usage, let's test the concept with a simpler example.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp; You should be able to run the code below. See whether what comes out of PDF is what you want. I don't think it is and I think my code shows that you can't "switch" backgrounds in mid-cell using your original technique. There is a way to make 2 cells -- one for your first line and one for your third line. However, the downside of this technique is that you won't be able to change the color and text of the "Third Line" (such as when TYPE changes) without "macro-izing" your code.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;Cynthia&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;ods _all_ close;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;options nodate nonumber;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;title; footnote;&lt;/STRONG&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;ods html file='c:\temp\show_compute_before.html';&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;ods rtf file='c:\temp\show_compute_before.rtf';&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;ods pdf file='c:\temp\show_compute_before.pdf';&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;ods escapechar='^';&lt;/STRONG&gt;&lt;BR /&gt;&amp;nbsp; &lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;** only some of the attributes in the STYLE(LINES) override will be used;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;proc report data=sashelp.class nowd&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp; style(lines)={textdecoration=underline fontsize=14pt fontstyle=italic&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; background=pink foreground=purple fontweight=bold};&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp; column name age sex height weight;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp; compute before _page_ / left&amp;nbsp;&amp;nbsp; style=[Font_weight=bold foreground=green background=yellow];&amp;nbsp; &lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ** colors in COMPUTE statement will override what is in PROC REPORT statement;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ** colors in ESCAPECHAR style override will override what is in COMPUTE statement;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; line '^{style[color=cyan background=cxdddddd]First Line}'&amp;nbsp;&amp;nbsp;&amp;nbsp; ; &lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; line '^{style[textdecoration=underline asis=on]^{nbspace 1}}';&amp;nbsp;&amp;nbsp; /* Non-breaking space will have 1 underscore in some dest*/&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; line '^{style[color=black background=lightgreen]Third Line}'&amp;nbsp;&amp;nbsp;&amp;nbsp; ;&amp;nbsp;&amp;nbsp; &lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp; endcomp;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;run;&lt;/STRONG&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;ods _all_ close;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;title;&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;ods html file='c:\temp\show_compute_alternate.html';&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;ods rtf file='c:\temp\show_compute_alternate.rtf';&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;ods pdf file='c:\temp\show_compute_alternate.pdf';&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;ods escapechar='^';&lt;/STRONG&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;** the issue with this alternate approach is that you cannot change the text;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;** "Third Line" without "macro-izing" your code. Right now, "Third Line" will be a fixed string.;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;proc report data=sashelp.class nowd&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp; style(header)={background=lightgreen color=black}&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp; style(lines)={textdecoration=underline fontsize=14pt fontstyle=italic&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; background=pink foreground=purple fontweight=bold};&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp; column ("^{style[just=l textdecoration=underline]Third Line}" name age sex height weight);&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp; define name / style(header)={background=white foreground=black};&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp; define age / style(header)={background=cxeeeeee foreground=red};&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp; define sex / style(header)={background=cxcccccc foreground=navy};&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp; define height / style(header)={background=cxaaaaaa foreground=lightgreen};&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp; define weight / style(header)={background=cx888888 foreground=cyan};&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp; compute before _page_ / left&amp;nbsp;&amp;nbsp; style=[Font_weight=bold foreground=green background=yellow];&amp;nbsp; &lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ** colors in COMPUTE statement will override what is in PROC REPORT statement;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; line 'First Line'&amp;nbsp;&amp;nbsp;&amp;nbsp; ; &lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp; endcomp;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;run;&lt;/STRONG&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;ods _all_ close;&lt;/STRONG&gt;&lt;BR /&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;title;&lt;/STRONG&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 23 Feb 2014 03:42:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-decorate-line-in-Proc-Report/m-p/182994#M46606</guid>
      <dc:creator>Cynthia_sas</dc:creator>
      <dc:date>2014-02-23T03:42:08Z</dc:date>
    </item>
    <item>
      <title>Re: How to decorate line in Proc Report?</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-decorate-line-in-Proc-Report/m-p/182995#M46607</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="color: #222222; font-family: arial; font-size: small; background-color: #ffffff;"&gt;Cynthia,&lt;/SPAN&gt;&lt;/P&gt;&lt;P style="color: #222222; font-family: arial; font-size: small;"&gt;&lt;/P&gt;&lt;P style="color: #222222; font-family: arial; font-size: small;"&gt;Thanks for your time and interest. I appreciate your efforts on this posting and solution.&lt;/P&gt;&lt;P style="color: #222222; font-family: arial; font-size: small;"&gt;&lt;/P&gt;&lt;P style="color: #222222; font-family: arial; font-size: small;"&gt; I learned that it is not feasible to change &lt;SPAN style="color: #333333; font-family: Arial, sans-serif;"&gt;a single cell from COMPUTE BEFORE to have 2 different background colors. PDF file shows cell with only one color.&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P style="color: #222222; font-family: arial; font-size: small;"&gt;&lt;/P&gt;&lt;P style="color: #222222; font-family: arial; font-size: small;"&gt; Could you please shed some more lights on&lt;/P&gt;&lt;P style="color: #222222; font-family: arial; font-size: small;"&gt;" &lt;SPAN style="color: #333333; font-family: Arial, Helvetica, sans-serif;"&gt;However, the downside of this technique is that you won't be able to change the color and text of the "Third Line" (such as when TYPE changes) without "macro-izing" your code."&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="color: #333333; font-family: Arial, Helvetica, sans-serif;"&gt;&amp;nbsp; Regards, &lt;/P&gt;&lt;P style="color: #333333; font-family: Arial, Helvetica, sans-serif;"&gt; Girish Patel &lt;SPAN style="font-size: 12.222222328186035px;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 23 Feb 2014 14:35:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-decorate-line-in-Proc-Report/m-p/182995#M46607</guid>
      <dc:creator>GPatel</dc:creator>
      <dc:date>2014-02-23T14:35:20Z</dc:date>
    </item>
    <item>
      <title>Re: How to decorate line in Proc Report?</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-decorate-line-in-Proc-Report/m-p/182996#M46608</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi:&lt;/P&gt;&lt;P&gt;&amp;nbsp; The fact is that making a spanning header will allow you to have a separate "cell" in which to put your "Third Line" -- but the spanning headers, like the other column header cells are fixed, they don't change. The LINE statement in your COMPUTE block can write the MAKE information, as it changes, but while "Third Line" is just text -- it will stay just text. You can't have the spanning header change with each unique make/type combination without invoking PROC REPORT for every unique combination of MAKE and TYPE. You can't write to the spanning header with a LINE statement. What is in the COLUMN statement can't be "touched" by a LINE statement.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; The fact is that if you were happy with or could live with having the Make: and Type: in one cell and did NOT need to have a different background or you could live with a different foreground color for Make and Type (totally do-able), then your current code would work. It is only that you want something that PROC REPORT and PDF will not do "out of the box" that leads to the need for a "macro-ized" solution. This is the reason that people turn to SAS Macro processing.&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&amp;nbsp; Space here is too limited to go into a full example of macro-izing a solution. Do you know about SAS Macro programs and SAS Macro variables? They are frequently used to generate repeatable, re-runnable code, as described in this paper (&lt;A href="https://support.sas.com/resources/papers/proceedings13/120-2013.pdf"&gt;https://support.sas.com/resources/papers/proceedings13/120-2013.pdf&lt;/A&gt;) which is aimed at beginners.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; But, the code below shows the use of macro variables to generate a customized PROC REPORT for 1 unique MAKE/TYPE combination (ACURA/SEDAN). There are ways with SAS macro processing to create macro variables so that in your macro program you could have a %DO loop go through the entire list and generate 1 PROC REPORT step for every unique MAKE/TYPE combination. But this program would be the core place to start.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cynthia&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;** define macro variables so every invocation of PROC REPORT;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;** will use these macro variables for one make/type combo that you want;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;** (macro variables can be generate automatically from data);&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;** so this is an example of 1 make/type combo;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;%let &lt;SPAN style="color: #ff00ff;"&gt;make1&lt;/SPAN&gt; = Acura;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;%let &lt;SPAN style="color: #ff00ff;"&gt;type1&lt;/SPAN&gt; = Sedan;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;%let &lt;SPAN style="color: #ff00ff;"&gt;mback&lt;/SPAN&gt; = yellow;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;%let &lt;SPAN style="color: #ff00ff;"&gt;tback&lt;/SPAN&gt; = lightgreen;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;ods pdf file="c:\temp\report_onemake_onetype.pdf" notoc;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;ods escapechar='^';&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;** with macro variables, you can alter the spanning header in the COLUMN;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;** statement -- there are other techniques that would allow you to;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;** automatically generate the list of unique make/type combinations.;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;** and using proc format, you could assign diff colors for diff make and diff type;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;proc report data=sashelp.cars nowd&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;&amp;nbsp; style(header)={&lt;SPAN style="color: #ff00ff;"&gt;background=&amp;amp;tback&lt;/SPAN&gt; color=black just=l}&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;&amp;nbsp; style(lines)={textdecoration=underline fontsize=14pt fontstyle=italic&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; background=pink foreground=purple fontweight=bold};&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;&amp;nbsp; where make = &lt;SPAN style="color: #ff00ff;"&gt;"&amp;amp;make1"&lt;/SPAN&gt; and type = &lt;SPAN style="color: #ff00ff;"&gt;"&amp;amp;type1"&lt;/SPAN&gt;;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;&amp;nbsp; Columns ("^{style[textdecoration=underline just=l]Type: &lt;SPAN style="color: #ff00ff;"&gt;&amp;amp;Type1&lt;/SPAN&gt;}" Make model Type Origin MSRP Invoice ) ;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;&amp;nbsp; Define make / Order Noprint;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;&amp;nbsp; Define model / 'Model'&amp;nbsp; style(header)={background=cxeeeeee foreground=red just=c};&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;&amp;nbsp; Define type / Order Noprint;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;&amp;nbsp; Define origin / Order Noprint;&amp;nbsp; &lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;&amp;nbsp; Define MSRP / sum analysis style(header)={background=cxeeeeee foreground=red just=c};&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;&amp;nbsp; Define invoice / sum analysis style(header)={background=cxeeeeee foreground=red just=c}; &lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;&amp;nbsp; break after type / page;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;&amp;nbsp; compute before _page_ / left&amp;nbsp;&amp;nbsp; style=[Font_weight=bold foreground=black &lt;SPAN style="color: #ff00ff;"&gt;background=&amp;amp;mback&lt;/SPAN&gt;];&amp;nbsp; &lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ** colors in COMPUTE statement will override what is in PROC REPORT statement;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; line "Make: &lt;SPAN style="color: #ff00ff;"&gt;&amp;amp;make1&lt;/SPAN&gt;"&amp;nbsp;&amp;nbsp;&amp;nbsp; ; &lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;&amp;nbsp; endcomp;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;run;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;ods _all_ close;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;&lt;STRONG&gt;title;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 24 Feb 2014 03:29:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-decorate-line-in-Proc-Report/m-p/182996#M46608</guid>
      <dc:creator>Cynthia_sas</dc:creator>
      <dc:date>2014-02-24T03:29:25Z</dc:date>
    </item>
    <item>
      <title>Re: How to decorate line in Proc Report?</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/How-to-decorate-line-in-Proc-Report/m-p/182997#M46609</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Cynthia,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This works fine as expected. I need to modify SAS code to use Macro logic. Its doable.&amp;nbsp; &lt;/P&gt;&lt;P&gt;Again, thanks for your insight and optimum solution.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Girish Patel&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 24 Feb 2014 23:20:19 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/How-to-decorate-line-in-Proc-Report/m-p/182997#M46609</guid>
      <dc:creator>GPatel</dc:creator>
      <dc:date>2014-02-24T23:20:19Z</dc:date>
    </item>
  </channel>
</rss>

