Last reviewed on September 17, 2013   —  12 Comments

Use this macro to disable the blank subject warning in Outlook 2010.

If you are looking for a macro to warn you that the subject is blank in earlier versions of Outlook, see Macro to Warn Before Sending a Message with a Blank Subject.

Please note: If you need help with this macro, please use the comments section below.

To use, open the VBA Editor using Alt+F11 and paste this into ThisOutlookSession.

Reprinted with permission of Peter Marchert

Option Explicit
' Prevents Outlook 2010 no-subject warning message
' (c) Peter Marchert -
' 2010-07-15 Version 1.0.0
' 2010-07-19 Version 1.0.1
' 2010-08-01 Version 1.1.0
' 2010-08-31 Version 1.1.1

Private WithEvents colInspectors As Outlook.Inspectors

Private Sub Application_Startup()

Set colInspectors = Outlook.Inspectors

End Sub

Private Sub colInspectors_NewInspector(ByVal Inspector As Inspector)

Dim objItem As Object

On Error GoTo ExitProc

Set objItem = Inspector.currentItem

If InStr(LCase(objItem.MessageClass), "ipm.appointment") > 0 Then
If objItem.MeetingStatus = 0 Then GoTo ExitProc

End If

If objItem.EntryID = "" Then
If objItem.Subject = "" Then objItem.Subject = " "
If objItem.Location = "" Then objItem.Location = " "

End If


Set objItem = Nothing
Set Inspector = Nothing

End Sub

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

On Error Resume Next

Item.Subject = Trim(Item.Subject)
Item.Location = Trim(Item.Location)

End Sub

Private Sub Application_Quit()

Set colInspectors = Nothing

End Sub


    • Diane Poremsky says

      Press Alt+F11 to open the VB editor then expand the Project folder on the left. ThisOutlookSession is under it.

    • Diane Poremsky says

      That will open the VBA Editor. You can also open it by enabling the Developer ribbon in File, Customize ribbon then clicking the Visual Basic button on the Developer ribbon.

    • Diane Poremsky says

      Open the VBA editor (Alt+F11) expand Project1, select the code, delete it and Save the project.

  1. Kaci says

    I entered the code into ThisOutlookSession, and it still prompts me before I send a message. I copied the code starting at "option Explicit"... do I include that as well?

    • Diane Poremsky says

      This is an application start up macro - you need to restart outlook or click in the Application startup macro and press Run. This macro needs to be in ThisOutlookSession to work.

  2. Dale Thompson says

    I had to disable this "IF" statement for the macro to work, as my e-mails have an EntryID:

    'If objItem.EntryID = "" Then
    If objItem.Subject = "" Then objItem.Subject = " "
    If objItem.Location = "" Then objItem.Location = " "
    'End If

  3. JohnnyCakes says

    You must also do this for it to work (which is on the original page from which this is copied):

    Whilst in Outlook select File > Options > Trust Center > Trust Center Settings > Macro Settings > Seelct "Enable all macros..." > Tick "Apply macro security..." > OK.

Leave a Reply

Please post long or more complicated questions at OutlookForums by

If the Post Comment button disappears, press your Tab key.