Merhaba arkadaşlar.
Access 2010'da aşağıdaki kod ile 3 adet raporu pdf olarak D:\ sürücüsüne kayıt ettiriyorum.
ve aşağıdaki kod ile de dosyayı ekleyip göndermeye çalışıyorum.
Kendi kullandığım bilgisayarımda dosyaları ekleyip gönderiyor.
fakat, işyerindeki bilgisayar hata veriyor. ekteki jpg'de hata resmi var.
acaba neden olabilir.
fakat resmini eklediğim
hata iletisini veriyor
pdf dosyalar d:\ sürücüsünde mevcut, kaydettirmede bir sorun yok.
göndermede sıkıntı var.
Access 2010'da aşağıdaki kod ile 3 adet raporu pdf olarak D:\ sürücüsüne kayıt ettiriyorum.
Visual Basic
- Dim stDocName As String
- Dim stDocName2 As String
- Dim stDocName3 As String
-
- stDocName = "İrsaliye"
- stDocName2 = "HATA_LISTESI"
- stDocName3 = "CEKI_LISTESI"
-
- Dim Sayac As Long, Kosul As String
- For Sayac = 0 To Me.Liste0.ListCount - 1
- If InStr(1, Kosul, Me.Liste0.Column(2, Sayac)) = 0 Then Kosul = Kosul & Me.Liste0.Column(2, Sayac) & ", "
- Next Sayac
-
- Kosul = Mid(Kosul, 1, Len(Kosul) - 1)
-
-
- DoCmd.OpenReport stDocName, acViewPreview, , , acWindowNormal
- DoCmd.OutputTo acOutputReport, "İrsaliye", "PDFFormat(*.pdf)", "D:\İrsaliye.pdf", False
- DoCmd.Close acReport, "İrsaliye"
-
-
- DoCmd.OpenReport stDocName2, acViewPreview, , "IRS_KODU In(" & Kosul & ")", acWindowNormal
- DoCmd.OutputTo acOutputReport, "HATA_LISTESI", "PDFFormat(*.pdf)", "D:\Hata Listesi.pdf", False
- DoCmd.Close acReport, "HATA_LISTESI"
-
- DoCmd.OpenReport stDocName3, acViewPreview, , "IRS_KODU In(" & Kosul & ")", acWindowNormal
- DoCmd.OutputTo acOutputReport, "CEKI_LISTESI", "PDFFormat(*.pdf)", "D:\Çeki Listesi.pdf", False
- DoCmd.Close acReport, "CEKI_LISTESI"
ve aşağıdaki kod ile de dosyayı ekleyip göndermeye çalışıyorum.
Kendi kullandığım bilgisayarımda dosyaları ekleyip gönderiyor.
fakat, işyerindeki bilgisayar hata veriyor. ekteki jpg'de hata resmi var.
acaba neden olabilir.
Visual Basic
- Dim oItem As Outlook.MailItem
- Dim oitems As Items
- Set oOutlook = New Outlook.Application
- Set oItem = oOutlook.CreateItem(olMailItem)
- With oItem
- .Subject = "İrsaliye, Hata Raporu ve Çeki Listesi Ektedir"
- .To = Me.MAIL
- '.CC = ""
- '.Body = ""
-
- Set myAttachments = oItem.Attachments
-
- .Attachments.Add ("D:\İrsaliye.pdf")
- .Attachments.Add ("D:\Hata Listesi.pdf")
- .Attachments.Add ("D:\Çeki Listesi.pdf")
-
- Set myAttachments = Nothing
- .ReadReceiptRequested = False
- .DeleteAfterSubmit = True
- .Display
- '.Send
- End With
- Set oOutlook = Nothing
- Set oItem = Nothing
fakat resmini eklediğim
hata iletisini veriyor
pdf dosyalar d:\ sürücüsünde mevcut, kaydettirmede bir sorun yok.
göndermede sıkıntı var.

