LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

capturing multiple events in a single callback

Is it possible to capture multiple events in a single callback?

Right now im trying to manipulate a table in CVI. Its currently capturing the EVENT_ACTIVE_CELL_CHANGE event so that I can map which cell is currently selected. What i need to do next is capture the EVENT_VAL_CHANGED event so that i can take note of a change in the value of the cell and then perform an action based on that change. Is there any way to do that?
0 Kudos
Message 1 of 3
(3,053 Views)

Your code probably has the foloowing staemtns:

switch(event)

{

    case EVENT_ACTIVE_CELL_CHANGE :

       // do whatever

       break;

}  // end of switch statement

just add the statements below before the end of the switch:

   case EVENT_VAL_CHANGED :

      //enter your desired actions based on the change

      break;

 

 

Any events that occur can be similary handled inside the callback.

Bring up the UIR and in the upper left corner tyou will see an icon with  a hand with one finger extended (no--not *THAT* finger) onto a green dot.  Click on this button and move your mouse and click  the buttons over your table.  In the upper wight hand corner of the UIR window, you will see the events listed as they occur. 

0 Kudos
Message 2 of 3
(3,033 Views)
Perfect! Thanks so much!
0 Kudos
Message 3 of 3
(3,010 Views)