View Single Post
  #4  
Old June 15th 06, 09:55 PM posted to microsoft.public.outlook.program_vba
Dan Mitchell
external usenet poster
 
Posts: 58
Default CDO and SMTP Servers

wrote in
oups.com:
You can specify a SMTP server in the code. My questions is, does this
SMTP server have to be the SMTP server that the recipient uses to
retrieve his or her e-mail or can this be the SMTP server through
which I wish to send the e-mail? My initial testing seems to suggest
the former. Is the latter possible? If so, how do you authenticate
yourself to the SMTP server through which you are sending the e-mail?


It definitely doesn't have to be the server that the recipient uses --
the whole point of SMTP is that you send your mail off to the SMTP
server that the _sender_ uses, and then servers take care of getting it
from place to place until it arrives at the recipient's server, and then
the recipient gets it from there however they do that.

So as long as you know that the person running the _sending_ code can
send mail through the smtp server specified in the code, you're okay.

If the person running the sending code may vary, things are more
complex. You have two options:

1. Let them enter the server that they would usually use (and then deal
with getting that info into your code).

2. Use a fixed server -- but this is risky, because then the fixed
server has to be open to everyone (ie spam) or use authentication, and
I'm not sure how you do authentication with CDOSYS -- there may be
something in schemas.microsoft.com somewhere, though.

-- dan
Ads