Send an email from Excel
Author:
wktd
01 6th, 2009 in
xn--9ou.com
edit
Sub Senmail()
Dim objOutlook As Object
Dim objOutlookMsg As Object
Set objOutlook = CreateObject("Outlook.Application")
Set objOutlookMsg = objOutlook.CreateItem(0)
With objOutlookMsg
.To = "email@.com"
.Subject = "Test Subject"
.Body = "Test Body of the message"
.Send
End With
Set objOutlookMsg = Nothing
Set objOutlook = Nothing
End Sub
I'd like to able to pick up various cells from my workbook but when I reference the cell using the code "Sheet1.Range("C4")" I get a runtime error 424 Object required. Does anyone know what I'm doing wrong? Thanks
But I dont know VBA only Google.
http://www.rondebruin.nl/sendmail.htm
#If you have any other info about this subject , Please add it free.# |