BookmarkSubscribeRSS Feed
Sivan
Calcite | Level 5
Hi,
Is it possible to send an email from SAS with a hyper link to a file?
If so, can you send me the syntax?

Thanks,
Sivan.
4 REPLIES 4
Pramod_R
Calcite | Level 5
Sivan,

You can send a hyperlink fin a sas e-mail as shown below:


FILENAME mail1 EMAIL
TO=("xxxxx@gmail.com" )
From =("yyyyy@gmail.com")
SUBJECT ="test"
type="text/html"
CT= "text/html" ;


DATA _NULL_;
FILE mail1;
PUT 'Hello!!! ';
PUT "Link text ";
run;

However, it should be noted that the recipient of the email should have access to the url which you specify in the href statement.

Let me know if this makes sense!

Thanks,
Pramod

Message was edited by: Pramod.R Message was edited by: Pramod.R
Bill
Quartz | Level 8
An example of what I use very frequently:

filename mail email ' '

to=("fred@somewhere.com")
from="me@nowhere.com"

subject="Inventory Report for &sysdate";


data _null_;

file mail;

put "auto e-mail for Inventory Report";
put " ";
put "Click on the blue underlined path below to view/print file contents";
put " ";
put "\\MOFtp\\Directory\InvenRpt.pdf";
put " ";


run;
sbb
Lapis Lazuli | Level 10 sbb
Lapis Lazuli | Level 10
The last reply does not address the EMAIL content formatting and would be dependent you how your EMAIL client interprets the text-format (default) -- suggest reading up on using appropriate FILENAME statement parameters, as was mentioned earlier in this post-reply thread.

Scott Barry
SBBWorks, Inc.

Suggested Google advanced search argument, this topic / post:

filename html format email hyperlink site:sas.com
Sivan
Calcite | Level 5
Thanks a lot, it was really helpful!

SAS Innovate 2025: Call for Content

Are you ready for the spotlight? We're accepting content ideas for SAS Innovate 2025 to be held May 6-9 in Orlando, FL. The call is open until September 16. Read more here about why you should contribute and what is in it for you!

Submit your idea!

What is Bayesian Analysis?

Learn the difference between classical and Bayesian statistical approaches and see a few PROC examples to perform Bayesian analysis in this video.

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