The RightClicked event has different arguments for different objects:
Object |
See |
---|---|
ListView and Tab control |
|
TreeView control |
Occurs when the user clicks the right mouse button on the ListView control or the tab portion of the Tab control.
PocketBuilder applications In PocketBuilder applications, tap and hold the stylus to trigger the RightClicked event.
Event ID |
Objects |
---|---|
pbm_lvnrclicked |
ListView |
pbm_tcnrclicked |
Tab |
Argument |
Description |
---|---|
index |
Integer by value (the index of the item or tab the user clicked) |
Long. Return code choices (specify in a RETURN statement):
0 Continue processing
When the user clicks in the display area of the Tab control, the tab page user object gets an RButtonDown event rather than a RightClicked event for the Tab control.
This example for the RightClicked event of a ListView control displays a pop-up menu when the user clicks the right mouse button:
// Declare a menu variable of type m_main m_main m_lv_popmenu // Create an instance of the menu variable m_lv_popmenu = CREATE m_main // Display menu at pointerposition m_lv_popmenu.m_entry.PopMenu(Parent.PointerX(), & Parent.PointerY())
Occurs when the user clicks the right mouse button on the TreeView control.
PocketBuilder applications In PocketBuilder applications, tap and hold the stylus to trigger the RightClicked event.
Event ID |
Objects |
---|---|
pbm_tvnrclicked |
TreeView |
Argument |
Description |
---|---|
handle |
Long by value (the handle of the item the user clicked) |
Long. Return code choices (specify in a RETURN statement):
0 Continue processing
This example for the RightClicked event of a TreeView control displays a pop-up menu when the user clicks the right mouse button:
// Declare a menu variable of type m_main
m_main m_tv_popmenu
// Create an instance of the menu variable
m_tv_popmenu = CREATE m_main
// Display menu at pointer position
m_tv_popmenu.m_entry.PopMenu(Parent.PointerX(), &
Parent.PointerY())