Fired when the user clicks on the control.

Version Introduced: 3.0.1

Parameters

ParameterDescription
GroupIndex to the group clicked
ItemIndex to the item clicked
PointThe location of the mouse within the control
ButtonThe mouse button used to click on the control
ShiftIndicates whether or not the SHIFT key is down
CtrlIndicates whether or not the CONTROL key is down

Remarks

The OnClick event is fired when the user clicks anywhere on the control.

The Group and Item parameters indicates which group or item received the click. If both parameters are zero, then the user has not clicked on any group or item; rather the click occurred elsewhere on the control. If only the Item parameter is zero, then a group header was clicked. If both parameters are non-zero, then the user clicked on an item. In this case, the Group value indicates the group containing the item that was clicked and the Item value is the index to the clicked item relative to its group. For example, clicking the second item in the first group would set Group to 1 and Item to 2.

The Point parameter contains the mouse cursors coordinates relative to the upper left corner of the control. It contains the x and y positions delimited by a comma, e.g, "100,100".

The Button parameter indicates the button that is used to fire the click event. This value is "Left" if the left mouse button was pressedor "Right" if the right mouse button was pressed.

The Shift and Ctrl parameters indicate whether or not the SHIFT or CTRL keys, respectively, were pressed when the event was fired. If either key was pressed, then its corresponding parameter will have a value of 1.

Example

Transfer Param1 to Group 
Transfer Param2 to Item 
Transfer Param3 to Point 
Transfer Param4 to Button 
Transfer Param5 to Shift 
Transfer Param6 to Ctrl 

// Did the user click an item 
ItemClicked = (Group GT 0 and Item GT 0) 

// Did the user click a group header 
GroupClicked = (Group GT 0) 

// Did the user click outside all groups and items 
CtrlClicked = (Group EQ 0)
  • No labels