Forgot to Attach the Attachment again

  • Thread starter Thread starter Jack G
  • Start date Start date
J

Jack G

It's embarrassing when you send an email but forget to attach the
attachment! I'm trying to figure out how outlook could respond to a Send
Event by scanning my message looking for the strings "attach" or "enclos",
and if it finds any, checks to see if anything is attached. If not, it
would display a message box with something like "Are forgetting your
attachment, Dummy?".

I'm guessing many others have been down this path. Thanks for any help.

Jack
 
Thanks Sue!! Jeremy's code did exactly what I wanted! Only glitch was that
I needed to add the Reference "Redemption Outlook Library" (it was called
something else in the follow-up questions to Jeremy's post).

Just one more question -- Am I compromising security by using Redemption?
In other words, should my IT guy be OK with it?

Jack

For sample VBA code to do this,
http://www.outlookcode.com/codedetail.aspx?id=553

And see http://www.outlookcode.com/d/vbabasics.htm if you're just getting
started with Outlook VBA.


--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003

and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
 
Redemption is quite safe. You don't really need it, though, unless you're using a version of Outlook before OL2003. IN Ol2003 and later, you can just use the Item object as in this ItemSend routine:

Write code for the Application_ItemSend event handler, e.g.:

Private Sub Application_ItemSend _
(ByVal Item As Object, Cancel As Boolean)
If Item.Subject = "" Then
Cancel = True
MsgBox "Please fill in the subject before sending.", _
vbExclamation, "Missing Subject"
End If
End Sub


--
Sue Mosher, Outlook MVP
Author of Configuring Microsoft Outlook 2003

and Microsoft Outlook Programming - Jumpstart for
Administrators, Power Users, and Developers
 
Back
Top