BookmarkSubscribeRSS Feed
t30
Fluorite | Level 6 t30
Fluorite | Level 6

Hi,

 

I routinely have to send a proc freq result in my email as a report.

 

The flow is like this:

1. Extract data

2. Do some manipulation

3. Get the proc freq

4. Screenshot proc freq result and paste in the Outlook email

5. Send email

 

1-3 are already automated. But I still need to manually screenshot it and send the email on a daily basis.

 

What I wish to do is to fully automate this, if a scheduler is too advance, maybe at least I want to automate 4 and 5.

Any tips and advice on how to do so?

4 REPLIES 4
Reeza
Super User

Search on here, this is a common question and there are a multitude of solutions. In general, it's easier to do it as an attachment than as an embedded image, but I think there was this question on this in the last month on here.

 

EDIT: http://blogs.sas.com/content/sasdummy/2013/07/31/gmail-from-sas-program/

t30
Fluorite | Level 6 t30
Fluorite | Level 6
Unfortunately, can't afford an attachment. The receivers would always prefer an embedded html or image rather than having to click and view the attachment.
Kurt_Bremser
Super User

@t30 wrote:
Unfortunately, can't afford an attachment. The receivers would always prefer an embedded html or image rather than having to click and view the attachment.

Then embed ods html output into the mail like this:

ods _all_ close;
filename mymail email 'recipient@domain.com' subject="Test" content_type='text/html';
ods html file=mymail;
proc print data=sashelp.class;
run;
ods html close;

SAS Innovate 2025: Save the Date

 SAS Innovate 2025 is scheduled for May 6-9 in Orlando, FL. Sign up to be first to learn about the agenda and registration!

Save the date!

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