LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

How to generate an event by double - clicking on list item

Hi all,
 
I want to generate an event by double clicking on the list's first item and then move the second item in the in the first place. How can I do that?
 
Thank you all in advance.
0 Kudos
Message 1 of 3
(3,184 Views)

Create a callback function for the list box.

Under EVENT_COMMIT, use GetCtrlIndex to see which list item is selected, then SetCtrlIndex to increment it to the next item.

You can use GetNumListItems to make sure you don't go past the bottom of the list.

See the attached example.

 

Message 2 of 3
(3,171 Views)

You can try using the tree. Here is the treeList example program included with CVI, with an added tree callback function that does what you want (I think).

0 Kudos
Message 3 of 3
(3,153 Views)