BeforeDoubleClick Event Example

This example overrides the default double-click behavior for the chart floor.

Private Sub Chart_BeforeDoubleClick(ByVal ElementID As Long, _
        ByVal Arg1 As Long, ByVal Arg2 As Long, Cancel As Boolean)
    If ElementID = xlFloor Then
        Cancel = True
        MsgBox "Chart formatting for this item is restricted."
    End If
End Sub