BookmarkSubscribeRSS Feed
lcdelta
Calcite | Level 5

Dear all,

 

I would like to do the automatic page numbering with ODS PDF. Here is the code. And I did not get the right format. Please see the attached picture. Could anyone help? Thank you.

 

options leftmargin=0.5in rightmargin=0.5in orientation=landscape nodate nobyline; *nonumber;;
ods escapechar='^';
title j=c " " j=r "Page ^{thispage} of ^{lastpage}";
options pageno=1;

lcdelta_0-1741560001780.png

 

1 REPLY 1
Ksharp
Super User

I tested your code, and got no problem.

Maybe you could try other encoding SAS like unicode sas with utf-8 encoding.

options leftmargin=0.5in rightmargin=0.5in orientation=landscape nodate nobyline nonumber;
ods escapechar='^';
ods pdf file='c:\temp\x.pdf';
title j=c " " j=r "Page ^{thispage} of ^{lastpage}";
proc print data=sashelp.heart(obs=50) noobs;run;
ods pdf close;

Ksharp_0-1741571235816.png

 

hackathon24-white-horiz.png

2025 SAS Hackathon: There is still time!

Good news: We've extended SAS Hackathon registration until Sept. 12, so you still have time to be part of our biggest event yet – our five-year anniversary!

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
  • 1 reply
  • 281 views
  • 0 likes
  • 2 in conversation