How to use SmtpMail on non-standard port?

Z

Zean Smith

I have a SMTP server running on port 9025, but seems like this doesn't
work.

SmtpMail.SmtpServer = "192.168.34.15:9025";

SmtpMail.Send( mail );


I couldn't find any properties on SmtpMail let me configure the port number,
any idea?
 
Z

Zean Smith

Got error when trying to add those lines:

[HttpException (0x80004005): Could not access 'CDO.Message' object.]
System.Web.Mail.LateBoundAccessHelper.CallMethod(Object obj, String
methodName, Object[] args) +112
System.Web.Mail.CdoSysHelper.Send(MailMessage message) +1861
System.Web.Mail.SmtpMail.Send(MailMessage message) +150
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top