Hi Team,
I need to change color or make bold to character variable using proc format.
Please find below the code used.
data dsn;
length State County Community $10.;
input State $10.
County $9.
Community $8.
flag 2.
;
datalines;
California Calveras Wallace 1
;
run;
proc format cntlout=colormodel(keep=fmtname start end label type sexcl eexcl);
value $State 'California' = "fontWeight:bold;";
value flag 1 = "";
run;
data colormodel(drop=T);
set colormodel(rename=(TYPE=T));
length TYPE $32;
if FMTNAME eq 'STATE' then TYPE = 'flag';
else TYPE = 't';
run;
data colormodel;
format state $state.;
set dsn;
run;
Thanks,
Arnav
Text decoration is only possible in reporting procedures. There are numerous papers explaning anything relevant in detail.
That's not how proc format works. It acts as a recoding procedure with the rules being the input.
Style such as colour and font are not valid in a SAS dataset.
So what are you trying to do?
Yes I am trying to change Style such as colour and font in a SAS dataset to show in a web browser through SAS SNA and this browser is accessing this table and i need to do conditional highlighting
Search on lexjansen.com for papers by Cynthia Zender that show how to create stylish reports.
http://support.sas.com/resources/papers/proceedings13/366-2013.pdf
Join us for SAS Innovate April 16-19 at the Aria in Las Vegas. Bring the team and save big with our group pricing for a limited time only.
Pre-conference courses and tutorials are filling up fast and are always a sellout. Register today to reserve your seat.
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.