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

Hi All,

I am using    title&t"@R/RTF'\qc %str(%bquote(&&myheader&k))";  to set the content of my title in report.

There is a single quote mark in string &&myheader&k, when I use %put to print this macro variable, the output is fine, single quote mark is there, or if I delete @R/RTF'\qc, the title in output also contains single quote.

but if I use  title&t"@R/RTF'\qc %str(%bquote(&&myheader&k))", the title in output removed the single quote in my original title. I guess it is caused by single quote in @R/RTF'\qc.

can anyone please advise how to resolve this problem?

Many thanks

1 ACCEPTED SOLUTION

Accepted Solutions
sbxkoenk
SAS Super FREQ

Hello,

Is this solving your problem (%-sign !!);

%LET t=1;
%LET k=2;
%LET myheader2=%nrstr(a%'bc);
title; footnote;
title&t. "@R/RTF'\qc %str(%nrbquote(&&myheader&k))";
proc print data=sashelp.class(obs=5); run;

Koen

View solution in original post

2 REPLIES 2
sbxkoenk
SAS Super FREQ

Hello,

Is this solving your problem (%-sign !!);

%LET t=1;
%LET k=2;
%LET myheader2=%nrstr(a%'bc);
title; footnote;
title&t. "@R/RTF'\qc %str(%nrbquote(&&myheader&k))";
proc print data=sashelp.class(obs=5); run;

Koen

tinaz5012
Obsidian | Level 7

Awesome! Thank you very much!

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 25. Read more here about why you should contribute and what is in it for you!

Submit your idea!

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.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

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

View all other training opportunities.

Discussion stats
  • 2 replies
  • 675 views
  • 0 likes
  • 2 in conversation