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

I would like to create a PDF report that has different colored rows based on the value of my variable type. I would like the rows to be green when type='Complete', yellow when type='Planned' and red when type='At Risk'. I have tried running the following compute block:


     compute type;

     if type='Complete' then call define (_row_,'style','style=[BACKGROUND=lightGREEN]');

     if type='Planned' then call define (_row_,'style','style=[BACKGROUND=lightYELLOW]');

     if type='At Risk' then call define (_row_,'style','style=[BACKGROUND=lightRED]');

     endcomp;

I have used a run statement as well as an ods pdf close statement at the end of the proc report step but when I run this section of my code SAS indicates that Proc Report is still running and will not produce the PDF file. How can I successfully produce this report?

1 ACCEPTED SOLUTION

Accepted Solutions
Reeza
Super User

Add the nowd (nowindows) option to your proc report statement. Proc Report can be an interactive procedure, so you want to tell SAS that you want it to be non-interactive.

proc report data=panel_1 nowd;

View solution in original post

4 REPLIES 4
Reeza
Super User

Full code please and log please.

Did you include nowd in the proc report statement as well?

AKNess
Calcite | Level 5

My full code looks like this:

Proc Report.jpg

I'm not very familiar with Proc Report and am not sure if I'm using any of the options correctly.

Reeza
Super User

Add the nowd (nowindows) option to your proc report statement. Proc Report can be an interactive procedure, so you want to tell SAS that you want it to be non-interactive.

proc report data=panel_1 nowd;

AKNess
Calcite | Level 5

That did it! Thank you!

SAS Innovate 2025: Save the Date

 SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!

Save the date!

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