Hello All,
I'm using the below program to output to excel. I'm getting a lot of rows that are too high. I suspect this is because SAS is looking at the row that's the highest (there's one that has a lot more text in one column than the others) and setting all row heights to match it. How do I make it so the heights are dynamic for each row?
ODS LISTING CLOSE;
ods excel file="folder\test.xlsx"
style=htmlblue;
ods excel options(
flow='tables'
sheet_name ='test'
embedded_titles='yes'
sheet_interval="none"
orientation='landscape');
Title 'a title';
run;
PROC PRINT DATA= test noobs;
RUN;
ODS _ALL_ CLOSE;
This code does not demonstrate 'all rows too tall', only the row with long text 'wrapped'.
data cars; retain make model; length model $500; set sashelp.cars(obs=10); if _n_ = 7 then model = repeat(trim(model),25); run; ODS _ALL_ CLOSE; ods excel file="test.xlsx" style=htmlblue options( flow = 'tables' sheet_name = 'test' embedded_titles = 'yes' sheet_interval = "none" orientation = 'landscape' ); PROC PRINT DATA=cars noobs; Title '10 of the Cars data'; RUN; ODS _ALL_ CLOSE;
You might have data with leading spaces, hard spaces (A0x), or semi-long data that is not being measured and layed out by ODS EXCEL according to 'human-eye' 'font-point' expectations.
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!
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.