disabled Property

Microsoft FrontPage Visual Basic

disabled Property

Sets or returns a Boolean that represents the status of a specified object. True indicates that the object is enabled.

expression.disabled

expression    Required. An expression that returns one of the objects in the Applies To list.

Example

The following example inserts a check box into the active document, and then disables the check box.

    Sub DisableCheckBox()
    Dim objCheckBox As FPHTMLInputButtonElement

    ActiveDocument.body.insertAdjacentHTML where:="beforeend", _
        HTML:="<input type=""checkbox"" id=""newcheckbox"">" & vbCrLf

    Set objCheckBox = ActiveDocument.body.all.tags("input") _
        .Item("newcheckbox")

    objCheckBox.disabled = True

End Sub