Código:
Alguna idea.... es que estas cosas que pasan en unos si y en otros no... pff no se como buscarloPublic Sub enviarMail(ByVal asunto As String, ByVal cuerpo As String) Try Dim message As MailMessage = New MailMessage() message.From = New MailAddress("[email protected]") message.To.Add(New MailAddress("[email protected]")) message.Subject = asunto message.Body = cuerpo message.IsBodyHtml = False Dim client As SmtpClient = New SmtpClient() client.Host = "smtp.gmail.com" client.Port = 587 client.EnableSsl = True client.UseDefaultCredentials = False client.Credentials = New System.Net.NetworkCredential("usuario", "pass") Try client.Send(message) Catch ex As Exception Msgbox("Error SEND " & ex.Message) End Try message.Dispose() Catch ex As Exception Msgbox("Error " & ex.Message) End Try End Sub
gracias