ShiftKey Property Example

The event procedure in this example displays the Microsoft Office Web Components version number whenever the user double-clicks the chart workspace with the SHIFT key held down. Note that the event procedure in this example is declared as required by Visual Basic. For more information about using event procedures, see Declaring and Using Event Procedures.

Private Sub ChartSpace1_DblClick(ByVal ChartEventInfo As OWC.WCChartEventInfo)
    If ChartEventInfo.ShiftKey Then
        vers = ChartSpace1.MajorVersion & "." & ChartSpace1.MinorVersion & _
            " build " & ChartSpace1.BuildNumber
        MsgBox vers, Title:="MSOWC Version"
    End If
End Sub