How to make Microsoft Outlook prompt on empty subject?

Category: 

It’s important and mandatory that the emails we send have relevant "subject" to it. Almost all email clients have this feature, where it will prompt user about the empty subject.

Unfortunately, when i started using Ms Office Outlook (previously i was using Thunderbird) as this is what my new company using, i notice that Ms Outlook doesn't prompt if i miss out the subject.

Then i Google around and found the solution for it. Please follow the simple steps below which will prevent you from sending a mail without a subject.

Here are the below steps:

  • Open your Microsoft Office Outlook
  • Press Alt+F11. This opens the Visual Basic editor
  • On the Left Pane, one can see Project1 --> Microsoft Office Outlook Objects" --> "ThisOutlookSession".
  • Click on "ThisOutlookSession".
  • Copy and Paste the following code in the right pane.(Code Pane)
  1. Private Sub Application_ItemSend(ByVal Item As Object, Cancel As Boolean)
  2. Dim strSubject As String
  3. strSubject = Item.Subject
  4. If Len(strSubject) = 0 Then
  5. Prompt$ = "Subject is Empty. Are you sure you want to send the Mail?"
  6. If MsgBox(Prompt$, vbYesNo + vbQuestion + vbMsgBoxSetForeground, "Message without subject") = vbNo Then
  7. Cancel = True
  8. End If
  9. End If
  10. End Sub
  • Now save the code (Ctrl+S) and close the Visual Basic editor.

That's all, now you can test by sending an email without subject. If it doesn't prompt, you may try re-start your Ms Office Outlook application.

Comments

Add new comment