BookmarkSubscribeRSS Feed
efo4life
Calcite | Level 5

Hi,

 

I am trying to insert an image into a PDF document I am creating thru SAS but I am running thru a host of problems. I saw some codes on here which I tried but it didn't work.

 

One of the errors I am getting is this:

Unrecognized SAS option name ESCAPECHAR

 

Also the image doesn't load into my pdf document.

 

Please can anyone help with a simple piece of code that works.

 

Thanks,

 

Efe

 

 

 

 

2 REPLIES 2
ballardw
Super User

Please provide the code you are attempting. Best would be the code from the log with the error message.

 

Also, which version of SAS are you running?

Cynthia_sas
SAS Super FREQ
Hi:
ESCAPECHAR is NOT a system option. It is a separate statement:
ODS ESCAPECHAR='^';
to declare your ESCAPECHAR to use for inline formatting.

Also, the image will not even be attempted by ODS until the ESCAPECHAR syntax is correct. So posting your code will be useful.

This documentation example shows you the correct syntax for everything except PREIMAGE:
http://support.sas.com/documentation/cdl/en/odsug/67921/HTML/default/viewer.htm#p11xia2ltavr8ln17srq...

My suggestion is that, if you don't want to post your code, you should try to get this documentation example working and then once it works, look at using PREIMAGE to get your image into the PDF document following this example:
http://support.sas.com/kb/24/229.html

My only additional comment to the above Tech Support note is that ODS PDF has to be able to FIND the image at the point in time when the PDF file is being created, so if a relative name for the file location does not work, try an absolute path.

title j=l '^S={preimage="saslogo.jpg"}';
OR
title j=l '^S={preimage="c:\images\saslogo.jpg"}';

cynthia

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
  • 2 replies
  • 5421 views
  • 0 likes
  • 3 in conversation