Inspector.HideFormPage Method

Outlook Developer Reference

Hides a form page in the inspector.

Syntax

expression.HideFormPage(PageName)

expression   A variable that represents an Inspector object.

Parameters

Name Required/Optional Data Type Description
PageName Required String The display name of the page to be hidden.

Example

This Visual Basic for Applications (VBA) example uses HideFormPage to hide the "General" page of a newly-created ContactItem and displays the item.

Visual Basic for Applications
  Sub HidePage()
    Dim MyItem As Outlook.ContactItem
    Dim myPages As Outlook.Pages
    Dim myinspector As Outlook.Inspector
	
    Set MyItem = Application.CreateItem(olContactItem)
    Set myPages = MyItem.GetInspector.ModifiedFormPages
    myPages.Add "General"
    Set myinspector = Application.ActiveInspector
    myinspector.HideFormPage "General"
    MyItem.Display
End Sub

See Also