Morning all
I am using the following piece of code to send email via SMTP but I have a proxy server in the way. Can anyone tell me how to connect to the proxy server first please. I know the address and port of the proxy.
This code uses a reference library I downloaded.
Thanks
=====================================
Set m_oSmtp = New AOSMTPLib.Mail
'm_oSmtp.Reset()
m_oSmtp.FromAddr = "A1 PC Consultants Ltd"
m_oSmtp.ServerAddr = "smtp.hosts.co.uk"
'If you don't have a SMTP server, assign "" to ServerAddr,
'ANSMTP will send email via DNS lookup
'm_oSmtp.ServerAddr = ""
m_oSmtp.Subject = "test subject"
m_oSmtp.BodyText = "test body"
Call m_oSmtp.AddRecipient("Support Team", "gareth.r.jones@landg.com", 0)
If m_oSmtp.SendMail() = 0 Then
MsgBox "Message delivered"
Else
MsgBox m_oSmtp.GetLastErrDescription()
End If
I am using the following piece of code to send email via SMTP but I have a proxy server in the way. Can anyone tell me how to connect to the proxy server first please. I know the address and port of the proxy.
This code uses a reference library I downloaded.
Thanks
=====================================
Set m_oSmtp = New AOSMTPLib.Mail
'm_oSmtp.Reset()
m_oSmtp.FromAddr = "A1 PC Consultants Ltd"
m_oSmtp.ServerAddr = "smtp.hosts.co.uk"
'If you don't have a SMTP server, assign "" to ServerAddr,
'ANSMTP will send email via DNS lookup
'm_oSmtp.ServerAddr = ""
m_oSmtp.Subject = "test subject"
m_oSmtp.BodyText = "test body"
Call m_oSmtp.AddRecipient("Support Team", "gareth.r.jones@landg.com", 0)
If m_oSmtp.SendMail() = 0 Then
MsgBox "Message delivered"
Else
MsgBox m_oSmtp.GetLastErrDescription()
End If