BookmarkSubscribeRSS Feed
Cynthia_sas
Diamond | Level 26
Hi:
About #2...the only way I know to get the empty cells above region or product formatted is to set the default for ALL the headers to the color you want those cells (black/white) and then override all the other headers in DEFINE statements to be the other colors you want.

cynthia
[pre]
ods listing close;
ods tagsets.ExcelXp file='header_ques.xls' style=sasweb
options(embedded_titles='yes' sheet_name='Business Unit HA' absolute_column_width='9');
title 'make ALL headers white and black and then override the ones you want different';
proc report data=sashelp.shoes nowd
style(headers)={foreground=black background=white font_weight=bold};
where product in ('Boot', 'Sandal', 'Slipper');
column region product, ( sales inventory returns);
define region / group;
define product / across style(header)={foreground=white background=green};
define returns/ sum ;
define inventory / sum style(header)={foreground=black background=cyan};
define sales / sum style(header)={foreground=black background=cyan};
run;
ods _all_ close;[/pre]

hackathon24-white-horiz.png

2025 SAS Hackathon: There is still time!

Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!

Register Now

How to Concatenate Values

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.

SAS Training: Just a Click Away

 Ready to level-up your skills? Choose your own adventure.

Browse our catalog!

Discussion stats
  • 15 replies
  • 3943 views
  • 0 likes
  • 2 in conversation