How do I send a gmail email in vb.net?

前端 未结 6 1652
情书的邮戳
情书的邮戳 2021-01-05 20:49

I want to send an email, but it gives me an error.

I have this code:

Sub sendMail(ByVal title As String, ByVal content As String)
    Dim SmtpServer          


        
6条回答
  •  灰色年华
    2021-01-05 21:46

    There is some problem with google account, you need to switch off some security settings. After sending email over and over, I received email on one of my support account (for google), the email were:

    You recently changed your security settings so that your Google Account [trdjoko@gmail.com] is no longer protected by modern security standards. 
    
    If you did not make this change 
    Please review your Account Activity page at https://security.google.com/settings/security/activity to see if anything looks suspicious. Whoever made the change knows your password; we recommend that you change it right away. 
    
    If you made this change 
    Please be aware that it is now easier for an attacker to break into your account. You can make your account safer again by undoing this change at https://www.google.com/settings/security/lesssecureapps then switching to apps made by Google such as Gmail to access your account.   
    Sincerely,
    The Google Accounts team 
    

    So I switched of additional security and i worked fine.

提交回复
热议问题