SAS Procedures

Help using Base SAS procedures
BookmarkSubscribeRSS Feed
alwaz_searching
Calcite | Level 5

I tried with the below code but could not get the text underlined into line statment:

proc report data=quart_report  nowd  split= '*'

   style(lines)=[color=black backgroundcolor=white

              fontsize=2 textalign=l]

;

   column project dept cat;

   by dept ;

   define project         / display style(column) =[cellwidth = 0.75in] ;

   define dept            / display style(column) =[cellwidth = 0.75in] ;

   define cat             / display style(column) =[cellwidth = 0.75in] ;

 

compute after _page_ ;                  

line ' ' ;

line @1 bold  "^S={posttext='^-350x_____________________________________'}Available Categories:"  ;

line ' ' ;

line @1  'DESCRIPTION' bold;

line ' ' ;

line ' ' ;

line ' ' ;

endcomp;

run;

Any other suggestions???

3 REPLIES 3
Ksharp
Super User

What destination are you using ?

RTF use Raw Destination-Specific Codes .

'~R"\ul underlined text \ul0 "'

Ksharp

Cynthia_sas
SAS Super FREQ

Hi:

  The "raw" destination specific codes will work for RTF, but not for PDF or HTML. If you want a technique that would work for PDF, RTF or HTML, there is a new style attribute in 9.2 that will do underlining without the need for "raw" codes. The style attribute is TEXTDECORATION and something like this should work in RTF, PDF and HTML. Remember you will need your

ODS ESCAPECHAR='^';

statement first....then your compute block would be like what is shown below.

cynthia

ods escapechar='^';

 

ods html file='c:\temp\textdecoration.html' style=sasweb;

ods pdf file='c:\temp\textdecoration.pdf';

ods rtf file='c:\temp\textdecoration.rtf';

proc report data=quart_report  nowd  split= '*'

   style(lines)=[color=black backgroundcolor=white

                 fontsize=2 fontweight=bold] ;

   

   ...more code ...

 

compute after _page_ /style={just=l};                 

line ' ' ;

line @1 "^{style[textdecoration=underline just=l]Available Categories:}"  ;

line ' ' ;

line @1  '^{style[just=l]DESCRIPTION}';

line ' ' ;

line ' ' ;

line ' ' ;

endcomp;

 

run;

ods _all_ close;

sas-innovate-white.png

Our biggest data and AI event of the year.

Don’t miss the livestream kicking off May 7. It’s free. It’s easy. And it’s the best seat in the house.

Join us virtually with our complimentary SAS Innovate Digital Pass. Watch live or on-demand in multiple languages, with translations available to help you get the most out of every session.

 

Register now!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

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
  • 2360 views
  • 0 likes
  • 3 in conversation