Simply looking for a code that will take data from an excel spreadsheet to inline text in a new message in outlook. Not an attachment, that I can do. I Just cannot figure out how to send data to outlook in the message area via VBA.
Send Excel data to Outlook in message area
Collapse
X
-
1. Go through Excel document and loop through all rows and columns to collect data into a variable. Let’s say this variable will be sExcelData
2. Send collected text via e-mail
[PHP]
Dim objOutlook
Dim objMailItem
set objOutlook = createobject("O utlook.Applicat ion")
Set objMailItem = objOutlook.Crea teItem(olMailIt em)
With objMailItem
.To = "e-mail address"
.Subject = "put subject here"
.Body = sExcelData
.Send
End With
Set objOutlook = Nothing
Set objMailItem = Nothing[/PHP] -
iburyak......Th at was perfect....than ks from atljpe
Originally posted by iburyak1. Go through Excel document and loop through all rows and columns to collect data into a variable. Let’s say this variable will be sExcelData
2. Send collected text via e-mail
[PHP]
Dim objOutlook
Dim objMailItem
set objOutlook = createobject("O utlook.Applicat ion")
Set objMailItem = objOutlook.Crea teItem(olMailIt em)
With objMailItem
.To = "e-mail address"
.Subject = "put subject here"
.Body = sExcelData
.Send
End With
Set objOutlook = Nothing
Set objMailItem = Nothing[/PHP]Comment
Comment