BookmarkSubscribeRSS Feed
Echo___
Calcite | Level 5

Echo____0-1722526073117.png

 

This is what I want and this is my code which does not work.

 

 

proc printto new file="&outdir./&pgm..lst";
run;
 
proc report data=final nowd missing headskip headline split='@' formchar(2)='_' out=test;
column ("&tblline" expdur expdurc npct ptime);
define expdur / display noprint;
define expdurc / display 'Duration of exposure(*ESC*){super a}' width=26;
define npct / display 'Persons@n (%)' center width=15;
define ptime / display "Person time*{super b}" center width=15;
 
compute after _page_;
line @1 &stndrdls*'_';
line @1 "Abbreviations: NA=not applicable.";
line @1 "a Months defined in 30-day intervals (eg, 3 months=90 days).";
line @1 "b Person time=patient years of exposure (total exposure in days/360).";
line @1 "%=100 x n/Total, within each category.";
line @1 "Study included: D5985C00003.";
endcomp;
run;
proc printto print=print;
run;
3 REPLIES 3
PaigeMiller
Diamond | Level 26

Works for output to PDF, EXCEL and HTML. Does not work for output to .LST. I didn't try ODS RTF.

--
Paige Miller
ballardw
Super User

Are you expecting to see superscript in a LST file? Pretty sure Proc Printto only generates basic text for output directed to the listing destination which means all the ODS options like text color, background color, superscripts or subscripts are ignored.

data_null__
Jade | Level 19

Capture.PNGSuper script 2 is hex 'B2'x on extended ASCII table.

sas-innovate-white.png

Missed SAS Innovate in Orlando?

Catch the best of SAS Innovate 2025 — anytime, anywhere. Stream powerful keynotes, real-world demos, and game-changing insights from the world’s leading data and AI minds.

 

Register now

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
  • 1277 views
  • 2 likes
  • 4 in conversation