[How-To] Missed Outlook Attachment,get warned before its too late

Gmail labs has an interesting feature which warns you if you miss to attach an attachment when sending the mail. A similar feature can be achieved in Microsoft Outlook as well, using Visual Basic scripting. 

For those of you who wish to achieve the same in Outlook, here is the step by step process.

1.) Ensure that Macros are enabled for your Microsoft Office Outlook. Macros don’t work with Microsoft Outlook Express, therefore this setup cannot be achieved with Microsoft Outlook Express.

2.) Ensure that your security level is set to Medium. You can set the security level by clicking on Tools –> Macro –> Security. Set the desired level to Medium.

3.) Traverse through Tools –> Macro –> Visual Basic Editor ( Or press ALT + F11)

4.) Expand Project 1 by clicking on the + sign.

Project Edition in Outlook

Project Edition in Outlook

5.) Expand Microsoft Office Outlook Objects.

6.) Double click ThisOutlookSession.

Code for Attachment Detection

Code for Attachment Detection

7.) Copy paste the following code. 

Private Sub Application_ItemSend(ByVal Item As Object, Cancel As Boolean)

    Dim lngres As Long

    If InStr(1, Item.Body, "attach") <> 0 Then

        If Item.Attachments.Count = 0 Then

            lngres = MsgBox(" Found 'Attach' in message, but no attachment found - send anyway?", _

                            vbYesNo + vbDefaultButton2 + vbQuestion, "You asked me to warn you...")

            If lngres = vbNo Then Cancel = True

        End If

    End If

End Sub

8.) The above code looks for the term “attach” ( without quotes) in the message body. If you send mails in your local language which is other than English, replace the word “attach” to the word you would be interested in searching for. This will make the code look for that particular word.

9.) Once the code is pasted, click on Save and then Exit.

Detecting attachments in Outlook

Detecting attachments in Outlook

10.) From now on, if you create any mail with Attach in the mail body and try sending it without attaching any file, you will get an alert.

Enjoy no more missing attachments in your important mails. Hope this post helps.

Also read[How-To] Recover lost Outlook PST Password

Kingsoft Office 2007: Microsoft Office comes free

How-To: Display two time zones in Microsoft Outlook

Recovering ‘permanently’ deleted email in Microsoft Outlook 2003

Microsoft Outlook: Creating an Appointment From a Mail

You can also follow me on Twitter at http://twitter.com/vaibhav1981

Do stay tuned to Technofriends for more, one of the best ways of doing so is by subscribing to our feeds. You can subscribe to Technofriends feed by clicking here.









8 Responses

  1. […] original here: [How-To] Missed Outlook Attachment,get warned before its too late before its too how to technofriends tips tutorials before its too, how to, technofriends, tips, […]

  2. A worth tip… Useful…


  3. Thanks Pavan.

  4. […] Pandey from Technofriends shows how we may setup_outlook_to_warn_if_we_are_sending_a_mail_without_attachment_though_mentioned_in_the_body. It is better to get such warnings rather than sending another mail saying – Sorry, I forgot to […]

  5. Nice article.. This is really very helpful..

  6. […] [How-To] Missed Outlook Attachment,get warned before its too late […]

  7. […] [How-To] Missed Outlook Attachment,get warned before its too late […]

  8. […] Also read: [How-To] Missed Outlook Attachment,get warned before its too late […]

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: