merhaba arkadaşlar
aşagıdaki kodla gizli email gönderdiğimde gelen excel dosyasını indirdikten sonra açmaya çalıştığımda dosyaya erişim izniniz yok yada salt okunur durumda diyor ve açılmıyor bunu nedeni bulamadım yardım ederseniz sevinirim
Dim bWasNewRecord As Boolean
Dim objCDOMail As Object
Private Sub Komut29_Click()
Set objCDOMail = CreateObject("CDO.Message")
DoCmd.OutputTo acOutputTable, "DAĞITIM", acFormatXLS, "C:\xxxxxxx.xls", False, ""
objCDOMail.To = "xxxxxxxxx"
objCDOMail.From = "xxxxxxxxxxx"
objCDOMail.Subject = "xxxxx"
objCDOMail.AddAttachment "C:\xxxxx.xls"
objCDOMail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpusessl") = True
objCDOMail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
objCDOMail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "smtp.gmail.com"
objCDOMail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate") = 1
objCDOMail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendusername") = "xxxxxxx"
objCDOMail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendpassword") = "xxxxxx"
objCDOMail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25
objCDOMail.Configuration.Fields.Update
objCDOMail.Send
Set objCDOMail = Nothing
End Sub
aşagıdaki kodla gizli email gönderdiğimde gelen excel dosyasını indirdikten sonra açmaya çalıştığımda dosyaya erişim izniniz yok yada salt okunur durumda diyor ve açılmıyor bunu nedeni bulamadım yardım ederseniz sevinirim
Dim bWasNewRecord As Boolean
Dim objCDOMail As Object
Private Sub Komut29_Click()
Set objCDOMail = CreateObject("CDO.Message")
DoCmd.OutputTo acOutputTable, "DAĞITIM", acFormatXLS, "C:\xxxxxxx.xls", False, ""
objCDOMail.To = "xxxxxxxxx"
objCDOMail.From = "xxxxxxxxxxx"
objCDOMail.Subject = "xxxxx"
objCDOMail.AddAttachment "C:\xxxxx.xls"
objCDOMail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpusessl") = True
objCDOMail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2
objCDOMail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "smtp.gmail.com"
objCDOMail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate") = 1
objCDOMail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendusername") = "xxxxxxx"
objCDOMail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/sendpassword") = "xxxxxx"
objCDOMail.Configuration.Fields.Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 25
objCDOMail.Configuration.Fields.Update
objCDOMail.Send
Set objCDOMail = Nothing
End Sub