In your code I see that you try to connect to GMAIL using the EMAILSYS=SMTP option. That does not work. GMAIL uses a secure link to connect to the mail server and that is not supported in the current release of the SMTP option. So you must use EMAILSYS=MAPI. However it is important that the EMAILID is exactly (case sensitive) as it is defined in the mail client that handles the MAPI calls. In GMAIL the EMAILID is normally the mail address, without the domain information. E.g. I used the email address erik.t.sasgf2012@gmail.com for communications regarding SAS Global Forum 2012 and the login code for GMAIL was erik.t.sasgf2012. So that should be the value in the EMAILID option. Something similar applies when trying to send mails via Hotmail.
... View more