You are here: COM API reference > Designer object > Visible property

Visible property

Returns a Boolean value indicating whether or not the page can be displayed.

Property value

True if the page can be displayed, False if the page cannot be displayed.

Remarks

This property can be used to control the visibility of a page depending on runtime variables. The default extension will return the value of m_Designer.Visible. You can override this, if required.

Following is the default extension of this method in the form templates:

Private Property Get IAMExtensionPage_Visible() As Boolean
    On Error GoTo Error_handler
    
    If Not m_Designer Is Nothing Then
        ' Set the edit mode of the datasource
        IAMExtensionPage_Visible = m_Designer.Visible(Me)
        ' Todo
        ' Add your code here
    End If
    
    Exit Sub
Error_handler:
    MsgBox caption & " Visible: " & Err.Description
End Property

Example

Private Property Get IAMExtensionPage_Visible() As Boolean
    On Error GoTo Error_handler
    
    If Not m_Designer Is Nothing Then
 ' Only show this page for documents of the 'CADDrawing' document type
        If m_Designer.CurrentObject.DocumentType.Name <> "CADDrawing" Then
            IAMExtensionPage_Visible = False
        Else
            IAMExtensionPage_Visible = m_Designer.Visible(Me)
        End If
        
    End If
    IAMExtensionPage_Visible = True
    Exit Sub
Error_handler:
    MsgBox caption & " Visible: " & Err.Description
End Property
(missing or bad snippet)

IAMUIExtensionDesigner object


www.bluecieloecm.com