Selamlar. Yazdırma alanı, bir buton yardımı ile excel sayfasındaki bir hücreden isim alarak (jpeg ve ya bitmap) kaydedilip, yine excel sayfasında listelenen mail adreslerine mail olarak gönderilebilir mi?
DOSYA İndirmek/Yüklemek için ÜCRETLİ ALTIN ÜYELİK Gereklidir!
Altın Üyelik Hakkında Bilgi
Sub resim()
Dim olMailItem As Long
olMailItem = 0
Set s1 = Sheets("SIPARIS")
s1.Range("I2:N" & s1.[n65536].End(3).Row).CopyPicture xlScreen, xlBitmap
ActiveSheet.Paste
genislik = Selection.Width
yukseklik = Selection.Height
Selection.Cut
Set grafik = ActiveSheet.ChartObjects.Add(, , genislik, yukseklik)
grafik.Chart.Paste
grafik.Chart.Export "c:\deneme\" & Format(Date, "ddmmyy") & s1.[d33] & ".jpg"
grafik.Delete
For sat = 71 To s1.[b65536].End(3).Row
adres = adres & isaret & s1.Cells(sat, "b")
isaret = ";"
Next
Set prog = CreateObject("Outlook.Application")
Set posta = prog.CreateItem(olMailItem)
With posta
.To = adres
.Subject = "Rapor"
.Body = "Merhaba " & Chr(10) & Chr(10) & "Dosyanız ektedir." & Chr(10) & Chr(10) & "Saygılarımla"
.Attachments.Add "c:\deneme\" & Format(Date, "ddmmyy") & s1.[d33] & ".jpg"
.Display
.Send
End With
Set prog = Nothing
Set posta = Nothing
End Sub
Dim [B]olMailItem[/B] As Long
[B]olMailItem[/B] = [B]0[/B]
'
'
'
'