BookmarkSubscribeRSS Feed
🔒 This topic is solved and locked. Need further help from the community? Please sign in and ask a new question.
rodrichiez
Quartz | Level 8

Hello,

 

I've created a SP with a proc report definition to format the final result, but when I run the SP from SAS Ad-In for Office in Excel, the result is displayed with no format at all, I tried the macro below but it doesn't worked:

 

%MACRO setopt;
%if %upcase (&_odsdest) = RTF %then %do;
%let _odsstyle=rtf;
%let _odsstylesheet=;
%let _odsoptions=bodytitle startpage=no
nokeepn notoc_data;
%end;
%else %if %upcase (&_odsdest)= PDF %then %do;
%let _odsstyle=printer;
%let _odsstylesheet=;
%let _odsoptions=bookmarkgen=no compress=9 startpage=no;
%end;
%else %if %upcase (&_odsdest)= HTML %then %do;
%let _odsstyle=sasweb;
%let _odsstylesheet=;
%let _odsoptions= rs=none;
%end;
%else %if %upcase (&_odsdest)=TAGSETS.SASREPORT11 %then %do;
%let _odsstyle=normal;
%let _odsstylesheet=;
%let _odsoptions=;
%end;

 

PROC REPORT DATA=WORK.QUERY_FOR_FACT_CSAC_BK_0000 nowd headskip
style(header)= [cellheight=.20in font_weight=bold foreground=white background=darkblue]
style(lines)= [background=cxCDE6F4 cellheight=.10in bordercolor=black]
style(column)= [background=lightgrey foreground=blue];

 

What can I do?

1 ACCEPTED SOLUTION

Accepted Solutions
rodrichiez
Quartz | Level 8

Update:

 

Solution:

In SAS Add-In Properties, click on Results tab and select HTML as Format.

 

Smiley Very Happy

View solution in original post

3 REPLIES 3
pau13rown
Lapis Lazuli | Level 10

is there a particular variable that doesn't appear formatted? don't you need some define statements? there you can specify the format

rodrichiez
Quartz | Level 8

None of the variable appear formatted, I put define statements and even so when I run the SP from the SAS Add In in Excel the result is unformatted.

rodrichiez
Quartz | Level 8

Update:

 

Solution:

In SAS Add-In Properties, click on Results tab and select HTML as Format.

 

Smiley Very Happy

hackathon24-white-horiz.png

The 2025 SAS Hackathon has begun!

It's finally time to hack! Remember to visit the SAS Hacker's Hub regularly for news and updates.

Latest Updates

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
  • 3 replies
  • 1633 views
  • 0 likes
  • 2 in conversation