AnnotationMouseDown, AnnotationMouseMove, AnnotationMouseUp Events
Syntax
Sub ControlName_AnnotationMouseDown( Button As Integer, Shift As Integer, XPos As Double, YPos As Double, AnnotationIndex As Long, AnnotationPart As CWAnnotationParts)
Sub ControlName_AnnotationMouseMove( Button As Integer, Shift As Integer, XPos As Double, YPos As Double, AnnotationIndex As Long, AnnotationPart As CWAnnotationParts)
Sub ControlName_AnnotationMouseUp( Button As Integer, Shift As Integer, XPos As Double, YPos As Double, AnnotationIndex As Long, AnnotationPart As CWAnnotationParts)
Applies To
Purpose
AnnotationMouseDown is generated when you click the mouse on an annotation.
AnnotationMouseMove is generated when you move the mouse over an annotation.
AnnotationMouseUp is generated when you release the mouse over an annotation.
Remarks
These events generate only if CWGraph.TrackMode is set to cwGTrackAllEvents. If the TrackMode property is set to cwGTrackDragAnnotation, the AnnotationChange event is generated.
In Visual Basic, use the following constants with the Button and Shift parameters:
vbLeftButton | 1 | Left button is pressed |
vbRightButton | 2 | Right button is pressed |
vbMiddleButton | 4 | Middle button is pressed |
vbShiftMask | 1 | <Shift> key is pressed |
vbCtrlMask | 2 | <Ctrl> key is pressed |
vbAltMask | 4 | <Alt> key is pressed |
Parameters
Button As Integer
State of the mouse buttons. The Button argument can be any combination of the following values: 1 for the left button, 2 for the right button, or 4 for the middle button. For example, if both the left and right mouse buttons are pressed, the Button argument is 3 (1 + 2). In the AnnotationMouseUp event, the Button argument corresponds to the state of the buttons after the triggering button is released.
Shift As Integer
State of the <SHIFT> , <CTRL> , and <ALT> keys when the button specified in the Button argument is pressed, released, or moved. The Shift argument is a bit field with the least-significant bits corresponding to the <SHIFT> key (bit 0), the <CTRL> key (bit 1), and the <ALT> key (bit 2 ). Some, all, or none of the bits can be set, indicating that some, all, or none of the keys are pressed.
XPos As Double
X position of the mouse.
YPos As Double
Y position of the mouse.
AnnotationIndex As Long
Index of the annotation (zero-based).
AnnotationPart As CWAnnotationParts
Part of the annotation on which the event occurred.