CommandChecked Event
Occurs when the specified Microsoft Office Web Component determines whether the specified command is checked.
Private Sub Form_CommandChecked(ByVal Command As Variant, ByVal Checked As Object)
Command The command that has been verified as being checked.
Checked Set the Value property of this object to False to uncheck the command.
Remarks
The OCCommandId, ChartCommandIdEnum, and PivotCommandId constants contain lists of the supported commands for each Web component.
Example
The following example demonstrates the syntax for a subroutine that traps the CommandChecked event.
Private Sub Form_CommandChecked( _ ByVal Command As Variant, ByVal Checked As Object)
Dim intResponse As Integer Dim strPrompt As String strPrompt = "Uncheck the command?" intResponse = MsgBox(strPrompt, vbYesNo) If intResponse = vbYes Then Checked.Value = False Else Checked.Value = True End If End Sub