Using VB, specific cell data into email subject

G

Guest

Using VB is it possible to use specific cell data and import this into the
subject field of an email

Can easliy create code to email the excel document succesfully, but need to
grab certain information from specific cells and put this into the subject
line
using office 2003
 
J

Jason Morin

I've never worked with the Outlook object model, but
after scanning some of Ron de Bruin's code at:

http://www.rondebruin.nl/sendmail.htm

wouldn't you use something like:

Dim OutApp As Outlook.Application
Dim OutMail As Outlook.MailItem
Set OutApp = CreateObject("Outlook.Application")
Set OutMail = OutApp.CreateItem(olMailItem)

With OutMail
.Subject = Cells(1,1).Value 'Value in A1
End With
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top