Results 1 to 12 of 12

Thread: [RESOLVED] Email setup (SMTP, port, SSL, etc) - did it change in Windows 10

Threaded View

  1. #1

    Thread Starter
    New Member
    Join Date
    Jul 2007
    Posts
    14

    Resolved [RESOLVED] Email setup (SMTP, port, SSL, etc) - did it change in Windows 10

    My application which has SMTP email abilities has stopped working since the advent of W10. Does anyone know if something has changed? Worked on every other platform.

    Current app asks user for:
    - SMTP server
    - server port
    - whether to use SSL or not (with warning if turned off - "most email servers use SSL...")
    - checkbox for Server authentication required
    - User ID (email address)
    - display name
    - email PW

    Code for the "Send test email" as follows:
    Code:
    On Error GoTo hell
        
        temp = formEmailSetup.MousePointer
        formEmailSetup.MousePointer = vbHourglass
        'check validity of info
        If txtServer = "smtp.example.com" Or txtUserName = "[email protected]" Or txtDisplayName = "Your Name Here" Then
            MsgBox "Enter your information into all boxes."
            Exit Sub
        End If
        If VBA.Trim(txtServer) = "" Or VBA.Trim(txtUserName) = "" Or txtDisplayName = "" Or txtPort = "" Then
            MsgBox "All boxes must have a value."
            Exit Sub
        End If
        'setup for email
        Set objemail = CreateObject("CDO.Message")
        objemail.From = txtDisplayName & "<" & txtUserName & ">"
        objemail.To = txtUserName
        objemail.Subject = "Test mail"
        objemail.TextBody = "Your ability to EMail customers is ready to go!" & vbNewLine & emailSig & vbNewLine & vbNewLine & "------------------------------------" & vbNewLine & "This message was generated automatically from XXX"
        
        objemail.Configuration.Fields.Item _
        ("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
        
        'Name or IP of Remote SMTP Server
        objemail.Configuration.Fields.Item _
        ("http://schemas.microsoft.com/cdo/configuration/smtpserver") = txtServer
        
        'Type of authentication, NONE, Basic (Base64 encoded), NTLM
        If chkAuthentication.Value = 1 Then
            objemail.Configuration.Fields.Item _
            ("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate") = cdoBasic
        Else
            objemail.Configuration.Fields.Item _
            ("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate") = cdoAnonymous
        End If
        'Your UserID on the SMTP server
        objemail.Configuration.Fields.Item _
        ("http://schemas.microsoft.com/cdo/configuration/sendusername") = txtUserName
        'Your password on the SMTP server
        objemail.Configuration.Fields.Item _
        ("http://schemas.microsoft.com/cdo/configuration/sendpassword") = txtPassword
        
        'Server port (typically 25)
        objemail.Configuration.Fields.Item _
        ("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = txtPort
        
        'Use SSL for the connection (False or True)
        If chkSSL.Value = 1 Then
            objemail.Configuration.Fields.Item _
                ("http://schemas.microsoft.com/cdo/configuration/smtpusessl") = True
        Else
            objemail.Configuration.Fields.Item _
                ("http://schemas.microsoft.com/cdo/configuration/smtpusessl") = False
        End If
        
        'Connection Timeout in seconds (the maximum time CDO will try to establish a connection to the SMTP server)
        objemail.Configuration.Fields.Item _
        ("http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout") = 60
        
        objemail.Configuration.Fields.update
        
        '==End remote SMTP server configuration section==
        
        
        objemail.Send
        formEmailSetup.MousePointer = temp
        If licensed = "yes" Then
            MsgBox "Mail successfully sent to: " & txtUserName
        Else
            MsgBox "Mail successfully sent to: " & txtUserName 
        End If
        Exit Sub
    hell:
        formEmailSetup.MousePointer = temp
        If Err.Number = -2147220973 Then
            MsgBox "The server could not make the connection to your email account. Please check the information and try again"
        ElseIf Err.Number = -2147220978 Then
            MsgBox "The Email server has responded with an error: " & Err.Description & "Your message will not be sent, and your email is not properly set up. Please contact your email provider for assistance."
        Else
            MsgBox "An internal error has occured. Code:4003-" & Err.Number & " " & Err.Description
        End If
    Error code being returned is -2147220973

    thoughts?
    Last edited by vbr1; May 7th, 2019 at 07:11 AM.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width