Microsoft Excel - A Mail should go automatically by updating the cell
Asked By Rajender Prasad
10-Feb-12 06:11 AM
Dear All,
In the attached sheet,
Whenver I update the Owner name, a mail should send to a particular person from the mailbox automatically with the comments "A row updated"
Automatically Mail should send.zip
Please help.
Prasad
Web Star replied to Rajender Prasad

Try this way
This will automatically send an email to any address/addresses whenever the workbook is saved. The only problem I have with it is that if you save it, you get the prompt, and when you close, excel automatically prompts you again. As long as you don't do a redundant save then you won't get a redundant auto email notification :)
Private Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, _
Cancel As Boolean)
Dim answer As String
answer = MsgBox("This is where you put the text to prompt the user if he wants to save or not" vbYesNo, "here is the title of that box")
If answer = vbNo Then Cancel = True
If answer = vbYes Then
'open outlook type stuff
Set OutlookApp = CreateObject("Outlook.Application")
Set OlObjects = OutlookApp.GetNamespace("MAPI")
Set newmsg = OutlookApp.CreateItem(olMailItem)
'add recipients
'newmsg.Recipients.Add ("Name Here")
newmsg.Recipients.Add ("sampleemailaddresshere@email.com")
'add subject
newmsg.Subject = "Subject line of auto email here"
'add body
newmsg.Body = "body of auto email here"
newmsg.Display 'display
newmsg.Send 'send message
'give conformation of sent message
MsgBox "insert confirmation box test here", , "title of confirmation box"
End If

Microsoft Outlook Outlook I have used Outlook Express and I am presently using Mozilla Thunderbird for my email client. I would like to try Microsoft Outlook, but when I try to open it, I get a message "Can Not Start Microsoft Outlook". Microsoft Outlook is in my Microsoft Office folder and I use MS Word and Excel
Email Merge??? Outlook Since Microsoft Word and Microsoft Excel can be used together to do a "Mail Merge" can Microsoft Outlook and Microsoft Excel be used to do an "Email Merge"??? Outlook General Discussions Microsoft Excel (1) Microsoft Word
How to export emails from Microsoft Outlook? Outlook When I export emails from Microsoft Outlook into Excel files, the file size for this Excel is so small, will it only include email message only without attached files? If yes how to export emails including attached files together? Thanks in advance for any suggestions Eric Outlook General Discussions Outlook (1) Excel (1) SuggestionsWhen (1) Kathleen (1) Orland (1) Eric (1) Attachments
cannot open excel file from outlook Excel Excel 2007 cannot open document eithout first saving and opening thru excel Excel Miscellaneous Discussions Microsoft Excel (1) Excel 2007 (1) Windows (1) Regserver (1) Outlook (1) Eithout (1) Try to re
How can I export my contact list to Microsoft Excel? Outlook I need to know how to export a contact list to Microsoft Excel. Can someone help me? Thank you. Outlook Contacts Discussions Microsoft Excel (1) Outlook (1) Office (1) KathywithaKtheonlyway (1) Importers (1) Exporters (1) Fiorello (1) Windows (1