ods word file="\test.docx";
ods escapechar="^";
proc report data=final1 nowd
style(report)=[verticalalign=middle cellspacing=0 width=100% bordercolor=black]
style(header)=[background=white verticalalign=middle just=center bordercolor=black borderbottomstyle=hidden]
style(column)=[just=center];
columns ("^S={borderbottomstyle=hidden bordertopstyle=hidden}Group" grpvar) ("Total A and B^{super a}" ("A" a1 a2) ("B" b1 b2));
define grpvar/display " " style(column)=[just=left] style(header)=[bordertopstyle=hidden];
define a1/display "A1";
define a2/display "A2";
define b1/display "B1";
define b2/display "B2";
run;
ods word close;
I am having trouble removing the line above the "Group" cell in the table below when creating .docx output, but I am able to create it with .rtf output.
current output:
desired output:
Thank you!
ODS Word is preproduction which means that things sometimes don't work as expected.
If you can get the output you want with RTF then use RTF. I have found in my limited attempts with ODS Word that anything except extremely simple tables seems to have an issue with one or more of the complications.
Also, please double check your posted proc report code. I tried substituting a data set I had for yours get errors with the Columns statement with a missing )
It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.
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.