PDA

View Full Version : Don't send mail with blank subject



ismailr
07-11-2008, 01:08 AM
Hi,
Can any one help to configure my outlook in such a way that
if the user forget to mention the subject and click on send button.
OUtlook should not send and should show a message "Please type subject and try again.."

Thanks

skatonni
07-24-2008, 03:30 PM
Try this in the ThisOutlookSession module

Provided by Sue Mosher at

http:\\www.eggheadcafe.com/forumarchives/outlook/Feb2006/post25927864.asp


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

Dim strMsg As String

Dim res As Long

If Item.Subject = "" Then

Cancel = True

strMsg = "Please fill in the subject before sending."

MsgBox strMsg, vbExclamation + vbSystemModal, "Missing Subject"

Item.Display

End If

End Sub