Date: Tue, 14 Sep 2010 07:30:54 -0500
Reply-To: Joe Matise <snoopy369@GMAIL.COM>
Sender: "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From: Joe Matise <snoopy369@GMAIL.COM>
Subject: Re: ODS Tagsets.Excelxp - Set multiple colors in header row of
PRINT output
In-Reply-To: <456B52C41B724C41B96561D7AD283E7D01F04EF0@mail.chpdm.umbc.edu>
Content-Type: text/plain; charset=ISO-8859-1
You can use style in the column definitions and refer to the header
specifically. IE: (not tested - not at work yet this AM)
proc print data = excelrpt noobs label
style(table)={font_face='Calibri' font_size=11}
style(header)={background=yellow};
var blank1-blank9 /style(header)={background=blue};
var medrecno medrec birthdat ssn lastnm firstnm currid
recipno elgbegdt elgenddt covgroup
covtype county age begdos enddos billpaydt prov provnpi provname
hosp source mco mconame;
run;
-Joe
On Tue, Sep 14, 2010 at 7:18 AM, Jack Clark <jclark@hilltop.umbc.edu> wrote:
> Hello,
>
>
>
> I am using the tagsets.excelxp destination to write PROC PRINT output to
> an Excel file. I have been asked to set the header information
> (variable labels) in Row 1 of the Excel file to have a background color
> of yellow for columns 1-9 and a background color of blue for the rest of
> the columns. Using the code below, I was able to STYLE the header to
> set the background color to yellow for the whole file - but I need some
> suggestions on how to set 2 different colors in the header.
>
>
>
> Could I set the whole header to blue using the method below, then
> override the color somehow for columns 1-9? Thanks for any ideas.
>
>
>
>
>
> ods tagsets.excelxp file = "C:\filename.xls" style = minimal
> options(sheet_name="sheetname");
>
>
>
> proc print data = excelrpt noobs label
>
> style(table)={font_face='Calibri' font_size=11}
>
> style(header)={background=yellow};
>
> var blank1-blank9 medrecno medrec birthdat ssn lastnm firstnm currid
> recipno elgbegdt elgenddt covgroup
>
> covtype county age begdos enddos billpaydt prov provnpi provname
> hosp source mco mconame;
>
> run;
>
>
>
> ods tagsets.excelxp close;
>
>
>
> Jack Clark
> Senior Research Analyst
> phone: 410-455-6256
> fax: 410-455-6850
> jclark@hilltop.umbc.edu
>
> University of Maryland, Baltimore County
> Sondheim Hall, 3rd Floor
> 1000 Hilltop Circle
> Baltimore, MD 21250
>
> Please consider the environment before printing this e-mail and/or any
> attachments.
>
>
> Confidentiality Notice: This e-mail may contain information that is legally
> privileged and that is intended only for the use of the addressee(s) named
> above. If you are not the intended recipient, you are hereby notified that
> any disclosure, copying of this e-mail, distribution, or action taken in
> reliance on the contents of this e-mail and/or documents attributed to this
> e-mail is strictly prohibited. If you have received this information in
> error, please notify the sender immediately by phone and delete this entire
> e-mail. Thank you.
>
|