BookmarkSubscribeRSS Feed
data_null__
Jade | Level 19

My BY variable is PAGE and I want to display Page 1, Page 2 etc. using and ENTRYFOOTNOTE.

 

I tried this which compiles

entryfootnote halign=right textattrs=(style=normal size=_footnotefontsize) eval(put("Page "||put(page,1.)||" of 2",$12.));

but generates the following NOTE and no output.

 

An expression used in a text statement resolves to a column. It must resolve to a constant. The expression will be ignored.

2 REPLIES 2
djrisks
Barite | Level 11

Hi, 

Simplifying it, you can you _byval_ to output the page number, you also need to add _byval_ to the dynamic statement too.

 

Of the top of my head, this may work:

entryfootnote halign=right textattrs=(style=normal size=_footnotefontsize) "Page " _byval_ " of 2";

 

 

RW9
Diamond | Level 26 RW9
Diamond | Level 26

This bit:

eval(put("Page "||put(page,1.)||" of 2",$12.));

 

Does not look right to me, the put() function takes characters and makes numbers, but in the above it is putting text to text?  Have you tried:

eval(cat("Page ",put(page,1.)," of 2");

SAS INNOVATE 2024

Innovate_SAS_Blue.png

Registration is open! SAS is returning to Vegas for an AI and analytics experience like no other! Whether you're an executive, manager, end user or SAS partner, SAS Innovate is designed for everyone on your team. Register for just $495 by 12/31/2023.

If you are interested in speaking, there is still time to submit a session idea. More details are posted on the website. 

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.

Get the $99 certification deal.jpg

 

 

Back in the Classroom!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 2 replies
  • 670 views
  • 0 likes
  • 3 in conversation