Hi,
I have a program which outputs two emails. Without having changed the macro/code relevant to the program, however, I receive the following error:
"ERROR: Email: Permission is denied.".
Any thoughts why this may be? Should I provide more information?
Thanks in advance!
--
some code:
%macro from_email;
%global from_email;
%if "&sysuserid."="ShivjiA" %then %let from_email=Azim Shivji <[email protected]>;
%else %if "&sysuserid."="HuqM" %then %let from_email=Maisha Huq <[email protected]>;
%else %let [email protected];
%mend from_email;
%from_email;
%put &from_email.;
options nodate nocenter;
options emailackwait=210;
ods listing close;
title;
footnote;
ods escapechar='^';
%macro email(to_email,to_name,to_reference);
filename outbox email
to=("&to_email.")
type="text/html"
subject="AHAR QC Report"
from="&from_email."
sender="&from_email."
replyto="&from_email."
bcc=("&from_email.")
;
ods html body=outbox style=journal rs=none options(pagebreak='no');
proc odstext;
p "Hi &to_name.,";
p " ";
p "XXX.";
p " ";
run;
ods html close;
%mend email;
%email( [email protected],
to_name=XXX,
to_reference=%str(XX, XX)
);
%email( [email protected],
to_name=XX,
to_reference=%str(XX, XX)
);
It's your turn to help shape SAS Innovate 2027. Share your expertise and inspire the SAS community.
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.
Ready to level-up your skills? Choose your own adventure.