- Katılım
- 17 Kasım 2009
- Mesajlar
- 295
- Excel Vers. ve Dili
- 2010
- Altın Üyelik Bitiş Tarihi
- 24-12-2023
Merhaba arkadaşlar aşağıdaki kod ile normal ev hattından mail gönderiyor fakat meb hattından izin vermiyor. mail gönderildi uyarısı veriyor fakat gönderme yapmıyor. meb hattından aşağıdaki kodlarda nasıl bir düzenleme yaparsam mail atabilirim.
Private Sub gonder_Click()
On Error Resume Next
If nakildilekcesi.acıklama = "" Then
MsgBox " Lütfen Mail göndermeden önce başvuru durumunu işaretleyiniz.", vbCritical, "UYARI"
Exit Sub
End If
Set GmailMesaj = CreateObject("CDO.Message")
Set CdoMesaj = CreateObject("CDO.Configuration")
Set aaa = CdoMesaj.Fields
schema = "http://schemas.microsoft.com/cdo/configuration/"
With aaa
.Item(schema & "sendusing") = 2
.Item(schema & "smtpserver") = "smtp.gmail.com"
.Item(schema & "smtpserverport") = 465
.Item(schema & "smtpauthenticate") = 1
.Item(schema & "sendusername") = nakildilekcesi.kurummail
.Item(schema & "sendpassword") = nakildilekcesi.kmailsifre
.Item(schema & "smtpusessl") = 1
.Update
End With
With GmailMesaj
.To = nakildilekcesi.alicimail
.From = nakildilekcesi.alicimail
.Subject = nakildilekcesi.konu 'başlık
.HTMLBody = nakildilekcesi.acıklama ' GENEL AÇIKLAMA
.Sender = ""
.ReplyTo = ""
Set .Configuration = CdoMesaj
SendEmailGmail = .Send
On Error Resume Next
End With
Set GmailMesaj = Nothing
Set CdoMesaj = Nothing
Set aaa = Nothing
Eposta = Empty
schema = vbNullString
MsgBox "mail gönderildi", , " "
End Sub
Private Sub gonder_Click()
On Error Resume Next
If nakildilekcesi.acıklama = "" Then
MsgBox " Lütfen Mail göndermeden önce başvuru durumunu işaretleyiniz.", vbCritical, "UYARI"
Exit Sub
End If
Set GmailMesaj = CreateObject("CDO.Message")
Set CdoMesaj = CreateObject("CDO.Configuration")
Set aaa = CdoMesaj.Fields
schema = "http://schemas.microsoft.com/cdo/configuration/"
With aaa
.Item(schema & "sendusing") = 2
.Item(schema & "smtpserver") = "smtp.gmail.com"
.Item(schema & "smtpserverport") = 465
.Item(schema & "smtpauthenticate") = 1
.Item(schema & "sendusername") = nakildilekcesi.kurummail
.Item(schema & "sendpassword") = nakildilekcesi.kmailsifre
.Item(schema & "smtpusessl") = 1
.Update
End With
With GmailMesaj
.To = nakildilekcesi.alicimail
.From = nakildilekcesi.alicimail
.Subject = nakildilekcesi.konu 'başlık
.HTMLBody = nakildilekcesi.acıklama ' GENEL AÇIKLAMA
.Sender = ""
.ReplyTo = ""
Set .Configuration = CdoMesaj
SendEmailGmail = .Send
On Error Resume Next
End With
Set GmailMesaj = Nothing
Set CdoMesaj = Nothing
Set aaa = Nothing
Eposta = Empty
schema = vbNullString
MsgBox "mail gönderildi", , " "
End Sub
