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

Apologies in advance for the question, I expecting that I've misunderstood some fundamental & basic concepts.

 

We've got a Stored Process that generates on screen (in a browser, via the Stored Process Web Application) a report that is basically a number of proc prints. We want to be able to automatically save this output to a HTML or PDF document. What I've read in the SP documentation suggests this is possible but all I've been able to find is directions for how to output directly to a file instead of in addition to the on screen output in the web application.

 

Can someone direct me to how I'd do this?

 

Thanks.

1 ACCEPTED SOLUTION

Accepted Solutions
Vince_SAS
Rhodochrosite | Level 12

Try this simple stored process, and be sure to specify the location and name of the PDF file that you want to save:

 

%STPBEGIN()

ods pdf file='specify-location-and-filename-for-PDF-file';

proc print data=sashelp.class; run; quit;

%STPEND()

Vince DelGobbo

SAS R&D

 

View solution in original post

3 REPLIES 3
Vince_SAS
Rhodochrosite | Level 12

I need some clarification about your goals.

 

Do you want the results displayed in the Web browser in HTML format and also have the results automatically saved in a PDF file?

 

Or do you want the results displayed in the Web browser in HTML format and click a button in the HTML to download the results in PDF format?

 

Or something else?

 

Vince DelGobbo

SAS R&D

jamesBFD
Obsidian | Level 7

Ideally I'd need the results displayed in the web browser, as they are now, and then an exact copy of that output saved as a PDF (or HTML file) saved automatically in a folder I've specified.

 

Thanks.

Vince_SAS
Rhodochrosite | Level 12

Try this simple stored process, and be sure to specify the location and name of the PDF file that you want to save:

 

%STPBEGIN()

ods pdf file='specify-location-and-filename-for-PDF-file';

proc print data=sashelp.class; run; quit;

%STPEND()

Vince DelGobbo

SAS R&D

 

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
  • 941 views
  • 0 likes
  • 2 in conversation