The Constant Innovator


Getting Microsoft Outlook to have a default location in calendar meetings / appointments
September 19, 2014, 4:13 pm
Filed under: Uncategorized

I’ve had a constant problem with Microsoft Outlook’s Calendar, wherein it prompts me for a location for a meeting if I haven’t specified one. Outlook pops up a dialog box:

 "Outlook has detected the following:
 - The location is not specified.
 Do you want to send the meeting anyway?
 Yes/No"

There are many cases where a meeting’s location is understood, or written in the subject, or I’m simply scheduling some work for myself, so getting prompted every time was a constant headache for several years. I’ve finally been able to solve that problem, by discovering this resource: http://blogs.technet.com/b/ewan/archive/2013/11/08/tip-o-the-week-196-change-outlook-meeting-duration.aspx And adapting the code as follows (Note that it can probably be optimized much further): First code snippet is exactly as mentioned:

Private objMeeting As clsMeeting

Private Sub Application_Quit()
    Set objMeeting = Nothing
End Sub

Private Sub Application_Startup()
     Set objMeeting = New clsMeeting
End Sub

Second code snippet is as follows:

    Private WithEvents olkIns As Outlook.Inspectors, _
            WithEvents olkApt As Outlook.AppointmentItem


    Private Sub Class_Initialize()
        Set olkIns = Application.Inspectors
    End Sub


    Private Sub Class_Terminate()
        Set olkIns = Nothing
    End Sub


    Private Sub olkApt_Unload()
        Set olkApt = Nothing
    End Sub

    Private Sub olkIns_NewInspector(ByVal Inspector As Inspector)
        If Inspector.CurrentItem.Class = olAppointment Then
            Set olkApt = Inspector.CurrentItem
                If Len(olkApt.Location) > 0 Then
                
                Else
                    olkApt.Location = "(default)"
                End If
        End If
    End Sub

Advertisements

Leave a Comment so far
Leave a comment



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 )

Twitter picture

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

Facebook photo

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

Google+ photo

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

Connecting to %s



%d bloggers like this: