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

I'm getting warning in log when using superscript 'Monotype Shorts" font symbol in the footnote.

Ex. 

ods rtf ;
footnote1 height=5 PCT justify=left
font='Monotype Sorts' color=CX009900 ^{super '6E'X} font=Ariel  " Point 1";
data a;
    a='a';
run;

proc print; run;
ods rtf close;

Log: 

WARNING: The FOOTNOTE statement is ambiguous due to invalid options or unquoted text.

If I try to quote i.e. "^{super '6E'X}", It displays some different symbols. Tried to store in macro variable however didn't work. Any solution ? Please don't ask to use different font. 

 

1 ACCEPTED SOLUTION

Accepted Solutions
Quentin
Super User

That last example with letter n I posted works for me on PC SAS 9.4M4:

 

ods escapechar='^' ;

ods rtf file='c:\junk\me.rtf'; footnote1 height=5 PCT justify=left font='Monotype Sorts' color=CX009900 "^{super n}" font=Arial " Point 1"; data a; a='a'; run; proc print; run; ods rtf close;

Quentin_0-1587748205966.png

There are no nested quotes, so all of the quotes have the usual meaning, to define a text string.

The Boston Area SAS Users Group is hosting free webinars!

Register now at https://www.basug.org/events.

View solution in original post

10 REPLIES 10
Quentin
Super User

Edit: Sorry, below is wrong. : )

 

Hi,

The quoted font name with a space is fine.  The problem is the superscript part is text for the title, so it needs to be in quotes, e.g.:

 

footnote1 height=5 PCT justify=left
font='Monotype Sorts' color=CX009900 "^{super '6E'X}" font=Arial  " Point 1";

 

The Boston Area SAS Users Group is hosting free webinars!

Register now at https://www.basug.org/events.
Lenith
Obsidian | Level 7
Thanks for reply, however that doesn't work. It displays a set of symbols instead of desired one because quote itself taken as a keypunch for a symbol.
Quentin
Super User

Gotcha, I see what you're doing now.  It's not a font problem. This code works:

 

footnote1 "AAA"  "^{super foo}" "BBB";

You need the ^{super foo} part inside quotes so that SAS knows it is part of the title value, and not an option for the title statement.

 

But you're trying to put a hex code in there, like:

footnote1 "AAA"  "^{super '6E'X}" "BBB";

And when you do that, SAS sees '6E'x as a 5-character string, instead of a hex value.  

 

Someone else will know a solution. I thought maybe:

footnote1 "AAA"  '^{super ''6E''X}' "BBB";

But that gives the same results as above.

 

Maybe there's some other way to encode '6E'X that doesn't require quotes?   Wait, isn't '6E'x just the character n?  

 

Looks like I get the result you want with just:

footnote1 height=5 PCT justify=left
font='Monotype Sorts' color=CX009900 "^{super n}" font=Arial  " Point 1";

 

 

 

The Boston Area SAS Users Group is hosting free webinars!

Register now at https://www.basug.org/events.
Lenith
Obsidian | Level 7
Tried with 'n' letter but that also didn't work. It prints 6 different symbols before "Point 1".
Lenith
Obsidian | Level 7
As soon as we put quotes after font "Monotype Sorts'is declared, quotes are interpreted as symbols, and that's problem i believe.
Quentin
Super User

That last example with letter n I posted works for me on PC SAS 9.4M4:

 

ods escapechar='^' ;

ods rtf file='c:\junk\me.rtf'; footnote1 height=5 PCT justify=left font='Monotype Sorts' color=CX009900 "^{super n}" font=Arial " Point 1"; data a; a='a'; run; proc print; run; ods rtf close;

Quentin_0-1587748205966.png

There are no nested quotes, so all of the quotes have the usual meaning, to define a text string.

The Boston Area SAS Users Group is hosting free webinars!

Register now at https://www.basug.org/events.
Lenith
Obsidian | Level 7
Oh yes, That worked. May be I did something wrong last time.
Thanks alot @Quentin 🙂
Tom
Super User Tom
Super User

Not that if you did want to use hexcode that did not happen to be something simple like a lowercase letter you could use the byte function to generate it as a string.

"^{super %qsysfunc(byte(06Ex))}"
Lenith
Obsidian | Level 7
Thank you @Tom . It did work as well. I was under impression that byte function works with numbers 1-255 only.
Tom
Super User Tom
Super User
BYTE() should work with numbers from zero to 255. Or in hexadecimal notation from 0x to 0FFx.

CFC_SAS_Communities_400x225.jpg

Call for content now open!

It's your turn to help shape SAS Innovate 2027. Share your expertise and inspire the SAS community.

Submit your proposal →

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
  • 10 replies
  • 9793 views
  • 5 likes
  • 3 in conversation