Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() I've have a macro that will send a generic email from Excel.. My nex problem in that I would like the subject of each email to reflect th infomation that are in two different cells of the workbook (say C5 an C7 of sheet1). How would I enter this in the macro to accomplish thi task? Thanks -- tanyhar ----------------------------------------------------------------------- tanyhart's Profile: http://www.excelforum.com/member.php...fo&userid=3514 View this thread: http://www.excelforum.com/showthread.php?threadid=54949 |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi Tanya,
See the tips section on any of Ron de Bruin's email pages. http://www.rondebruin.nl/sendmail.htm --- Regards, Norman "tanyhart" wrote in message ... I've have a macro that will send a generic email from Excel.. My next problem in that I would like the subject of each email to reflect the infomation that are in two different cells of the workbook (say C5 and C7 of sheet1). How would I enter this in the macro to accomplish this task? Thanks. -- tanyhart ------------------------------------------------------------------------ tanyhart's Profile: http://www.excelforum.com/member.php...o&userid=35148 View this thread: http://www.excelforum.com/showthread...hreadid=549499 |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Dim s as String
With worksheets("Sheet1") s = .Range("A1").Text & " " & .Range("B9").Text End With . . . Subject:=s, . . . -- Regards, Tom Ogilvy "tanyhart" wrote: I've have a macro that will send a generic email from Excel.. My next problem in that I would like the subject of each email to reflect the infomation that are in two different cells of the workbook (say C5 and C7 of sheet1). How would I enter this in the macro to accomplish this task? Thanks. -- tanyhart ------------------------------------------------------------------------ tanyhart's Profile: http://www.excelforum.com/member.php...o&userid=35148 View this thread: http://www.excelforum.com/showthread...hreadid=549499 |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() Tom, When I enter that into the macro and run it, I get a run-time error 9 Subscript out of range. Perhaps I have it in the wrong place. ub Mail_small_Text_Outlook() 'You must add a reference to the Microsoft outlook Library Dim myOutlook As Object Dim myMailItem As Object Dim strbody As String Dim s As String Set OutApp = CreateObject("Outlook.Application") Set OutMail = OutApp.CreateItem(olMailItem) strbody = "XXXXX" & vbNewLine & vbNewLine & _ "Your request for estimate has been received and is i progress." & vbNewLine & vbNewLine & _ "I have been assigned the responsibility to coordinat the return and will try to have the estimate returned to you by XXXX. & vbNewLine & _ "If the estimate can not be delivered by this date, yo will be notified." With Worksheets("Sheet1") s = .Range("A1").Text & " " & .Range("B9").Text End With With OutMail .to = "" .CC = "" .BCC = "" .Subject = s .Body = strbody .Display End With Set OutMail = Nothing Set OutApp = Nothing End Su -- tanyhar ----------------------------------------------------------------------- tanyhart's Profile: http://www.excelforum.com/member.php...fo&userid=3514 View this thread: http://www.excelforum.com/showthread.php?threadid=54949 |
#5
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]() Disregard, I figured it out. Thanks for your help -- tanyhar ----------------------------------------------------------------------- tanyhart's Profile: http://www.excelforum.com/member.php...fo&userid=3514 View this thread: http://www.excelforum.com/showthread.php?threadid=54949 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
email hyperlink - cell value in subject line | Excel Discussion (Misc queries) | |||
Export data in cell as the subject line in an email | Excel Worksheet Functions | |||
Subject line in email defaults to workbook file name. | Excel Discussion (Misc queries) | |||
Subject line in email defaults to workbook file name. | Excel Discussion (Misc queries) | |||
Code to Email with UNC in subject line | Excel Programming |