Dismiss Method

Microsoft Outlook Visual Basic

Dismiss Method

       

Dismisses the current reminder.

expression.Dismiss

expression   Required. An expression that returns a Reminder object.

Remarks

The Dismiss method will fail if there is no visible reminder.

Example

The following example dismisses all active reminders. A reminder is active if its IsVisible property is set to True.

Sub DismissReminders()
'Dismisses any active reminders

    Dim olApp As Outlook.Application
    Dim objRems As Reminders
    Dim objRem As Reminder

    Set olApp = Outlook.Application
    Set objRems = olApp.Reminders

    For Each objRem In objRems
        If objRem.IsVisible = True Then
            objRem.Dismiss
        End If
    Next objRem

End Sub