BookmarkSubscribeRSS Feed
SachinRuk
Calcite | Level 5
Hi,

I have the following piece of code.

ods pdf text="~S={just=left cellwidth=1.6in background=CX4D7EBF foreground=black} ~mName:
~S={background=white foreground=black} Sachin";


I want to have a blue box around the "Name" part and no background on the "Sachin" part. I also need this to be in one line.

How would you go about doing this.

Thanks in advance,
Sachin
1 REPLY 1
Andre
Obsidian | Level 7
Sachin,
It seems that the ods pdf destination did not accept those specification
which is more adapted to html and by extension to rtf

Andre
Play further with

[pre]
ods escapechar="~";
ods listing close;
ods html file="d:\temp\encadre.htm";
ods rtf file="d:\temp\encadre.rtf";
ods pdf file="d:\temp\encadre.pdf";
proc print data=sashelp.class;run;
*ods pdf text="~S={just=left cellwidth=1.6in background=CX4D7EBF foreground=black} ~mName:
~S={background=white foreground=black} Sachin" ;
ods text="~S={bordercolor=black borderwidth=0.1in just=left cellwidth=1.6in cellheight=0.5in foreground=black} Name:
~S={bordercolor=black} Sachin"; run;
ods text="~{style[bordercolor=black frame=box rules=all borderwidth=0.3in just=left cellwidth=1.6in foreground=black] Name:}
~{style[bordercolor=black background=gray foreground=black] Sachin}";
run;
quit;
ods _all_ close;
ods listing;
[/pre]

sas-innovate-2024.png

Don't miss out on SAS Innovate - Register now for the FREE Livestream!

Can't make it to Vegas? No problem! Watch our general sessions LIVE or on-demand starting April 17th. Hear from SAS execs, best-selling author Adam Grant, Hot Ones host Sean Evans, top tech journalist Kara Swisher, AI expert Cassie Kozyrkov, and the mind-blowing dance crew iLuminate! Plus, get access to over 20 breakout sessions.

 

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.

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