Sending Mail Problem with NTLM

Discussion in 'Python' started by Tommylicious, Oct 17, 2017.

  1. Tommylicious

    Tommylicious

    Joined:
    Oct 17, 2017
    Messages:
    1
    Likes Received:
    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?

    Code (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 = 'my-mail@myserver.com'
    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...
     
    Tommylicious, Oct 17, 2017
    #1
    1. Advertisements

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 (here). After that, you can post your question and our members will help you out.
Similar Threads
  1. HoustonComputerGuy@gmail.com

    "Failure Sending Mail" when using System.Net.Mail and ASP.Net 2.0

    HoustonComputerGuy@gmail.com, Dec 4, 2005, in forum: ASP .Net
    Replies:
    4
    Views:
    56,173
  2. =?Utf-8?B?T3Bh?=

    Sending Mail via System.Net.Mail problem

    =?Utf-8?B?T3Bh?=, Jan 25, 2006, in forum: ASP .Net
    Replies:
    3
    Views:
    3,896
    sachya
    Jan 31, 2006
  3. =?ISO-8859-1?Q?Andr=E9s_Berenguer?=

    Sending e-mail with attachments with the default e-mail client

    =?ISO-8859-1?Q?Andr=E9s_Berenguer?=, Aug 29, 2003, in forum: Java
    Replies:
    0
    Views:
    707
    =?ISO-8859-1?Q?Andr=E9s_Berenguer?=
    Aug 29, 2003
  4. shailajabtech@gmail.com
    Replies:
    0
    Views:
    2,192
    shailajabtech@gmail.com
    Sep 28, 2006
  5. Luke
    Replies:
    2
    Views:
    5,262
    Nigel Wade
    Mar 15, 2007
  6. satnamsarai@gmail.com

    Some get error failure sending mail ( System.Net.Mail)

    satnamsarai@gmail.com, Sep 21, 2007, in forum: ASP .Net
    Replies:
    2
    Views:
    4,929
    satnamsarai@gmail.com
    Sep 21, 2007
  7. Don Quijote de Nicaragua

    Error + Send Mail + ERROR: Failure sending mail.

    Don Quijote de Nicaragua, Jun 26, 2008, in forum: ASP .Net
    Replies:
    5
    Views:
    1,852
    Don Quijote de Nicaragua
    Jun 26, 2008
  8. Matthijs
    Replies:
    0
    Views:
    1,262
    Matthijs
    Dec 10, 2008
Loading...