BookmarkSubscribeRSS Feed
deleted_user
Not applicable
I am trying to insert a jpeg at the top of my report. I also would like a text under neath it. I have tried several ways with no success.

I tried this...
proc report data=CanxPctCnt nowd split='#' center
style={preimage='D:\Documents and Settings\amrapon\Desktop\Harley Davidson Report\Harley Logo For Top Of Report.jpg'};
title2 'Dealer: 0415';

I get the image, but then the tile appears above it. I would like it below the image.
3 REPLIES 3
Cynthia_sas
SAS Super FREQ
Hi:
Look at this Tech Support note -- even though it shows ODS PDF, the technique will work for ODS RTF or ODS HTML:
http://support.sas.com/kb/24/229.html

Using your method, the SAS title will come first, then the table, with the preimage before the table. The title ALWAYS comes first. So if you want the image and then the title, you'd have to move your PREIMAGE specification from the PROC REPORT step and into the TITLE statement and then whatever other text you want into the TITLE2 statement.

The ONLY thing you'll have to be careful of is that for RTF and PDF, the image location is the image file path when the RTF or PDF file is CREATED; whereas, for HTML, the image location that you specify is the image file path that will be needed when the HTML file is -LOADED- into the browser. Sometimes these are different locations...for example, the RTF and PDF location might be a local computer location, while the HTML location might be a web server location (such as where the HTML file and image will be stored when the HTML file is accessed).

cynthia
deleted_user
Not applicable
Ok, that worked for the titles! Thanks. But how come when I add the footnote, it causes the following error?....

options nodate nonumber;
ods pdf file="C:\PC_SAS\TEST FORMATTING.pdf";
ods escapechar='^';

proc report data=CanxPctCnt nowd split='#' center;
title
j=c '^S={preimage="D:\Documents and Settings\amrapon\Desktop\Harley Davidson Report\Harley Logo For Top Of Report.jpg"}'
j=c 'Dealer: 0415';
footnote1 j=r 'Page ^{thispage} of ^{lastpage}';


ERROR: No logical assign for filename .
ERROR: Internal error on replay for "page i of n" processing. Could be caused by out of memory,
out of disk space, or internal coding error. Check for other error messages above
indicating probable user error or resource constraints; if there are none, or if they make
no sense, please report this message and provide a test program to SAS Institute.
Cynthia_sas
SAS Super FREQ
Hi:
I believe you're running into this situation:
http://support.sas.com/kb/15/541.html

If you are working in SAS 9.2 and still encounter this issue, then you should work with Tech Support.

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