Startup Event

Microsoft Outlook Visual Basic

Startup Event

       

Occurs when Microsoft Outlook is starting, but after all add-in programs have been loaded. This event is not available in VBScript.

Sub object_Startup()

object   An expression that evaluates to an Application object.

Remarks

An Outlook Visual Basic for Applications macro can use this event procedure to initialize itself when Outlook starts.

Example

This Microsoft Outlook Visual Basic for Applications example maximizes the Outlook explorer window when Outlook starts.

Private Sub Application_Startup()
    Application.ActiveExplorer.WindowState = olMaximized
End Sub