Has anyone managed to get SendMailAuth to work consistently?

Discussion to talk about software related topics only.
barttech
Posts: 135
Joined: Fri Feb 20, 2009 12:59 pm

Re: Has anyone managed to get SendMailAuth to work consisten

Post by barttech »

rnixon,
I can get a host by name ok, so I assume the dns is set up right. I don't really understand how gateways do what they do, or how they should be setup, so I guess I have some 'continuing ed' to do. It gets out to the web fine, I can't get it to reach my mail server through telnet, but that hasn't worked from my work machine either, even though the netburner app works from here. It must either be the router, or the fact that the ISP is different at the two sites, and the remote site ISP might be blocking some things. I know the port number 25 is right for my mail server.
Thanks,
Sam
Ridgeglider
Posts: 513
Joined: Sat Apr 26, 2008 7:14 am

Re: Has anyone managed to get SendMailAuth to work consisten

Post by Ridgeglider »

If the ISP is different in the 2 sites, you may need to use IPsetup to reconfigure the IP settings including the gateway and DNS parameters. The gateway is usually the router address, often something like 192.168.1.1 in a small network. Try the google DNS servers at 8.8.8.8 and 8.8.4.4.
barttech
Posts: 135
Joined: Fri Feb 20, 2009 12:59 pm

Re: Has anyone managed to get SendMailAuth to work consisten

Post by barttech »

Thanks Ridgeglider,
I tried your suggestion, but it didn't help. I could get a host OK before, so my gateway and DNS were working (if I understand these things) with the defaults. It is the connect() that fails to connect. Maybe I just need to have the remote ISP be the same as my office ISP (means changing a customer's ISP).
Sam
barttech
Posts: 135
Joined: Fri Feb 20, 2009 12:59 pm

Re: Has anyone managed to get SendMailAuth to work consisten

Post by barttech »

Here's the deal: If you are using Verizon DSL for your ISP, whether you use SendMailAuth() or SendMailAsServer(), you need to change:
WORD SMTP_PORT = 587;
WORD SMTP_AUTH_PORT = 587;
This also works with my local ISP, they accept 25 or 587 I guess.
And you need to use a verizon.net email address (doesn't have to be a valid one) as your From Address.
Both seem to be working fine now.
I should have gone to
http://en.wikipedia.org/wiki/Simple_Mai ... ocol#Ports
about a month ago.
Sam
Post Reply