Sending Mail Problem with NTLM

Joined
Oct 17, 2017
Messages
1
Reaction score
0
I am trying to send an email via python, but it does not work. Can someone give me a hint, what I am doing wrong here?

Python:
import win32com.client
c = win32com.client.Dispatch('CDO.Configuration')
c.Fields.Item('cdoSendUsingMethod').Value = 2
c.Fields.Item('cdoSMTPServer').Value = 'smtp.myserver.de'
c.Fields.Item('cdoSMTPConnectionTimeout').Value = 10
c.Fields('cdoSMTPServerPort').Value = 25
c.Fields('cdoSMTPAuthenticate').Value = 2
c.Fields.Update()
m = win32com.client.Dispatch('CDO.Message')
m.Configuration = c
m.To = '[email protected]'
m.From = 'Test'
m.Htmlbody = '<H3><B>this is a test</B></H3>'
m.Subject = 'Testigertest'
m.Send()

The problem is here:
c.Fields('cdoSMTPAuthenticate').Value = 2

also using "cdontlm" instead of "2" doesn't really help...
 

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

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,581
Members
45,056
Latest member
GlycogenSupporthealth

Latest Threads

Top