LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Combo_NewComboBox: events EVENT_GOT_FOCUS and EVENT_LOST_FOCUS are not functioning

Hello,

 

We use CVI 8.5.1

We have a problem with the combo-box controls which are created at the runtime.

 

The event EVENT_GOT_FOCUS is released only by the first mouse click on the control, after that no focus event is released.

The event EVENT_LOST_FOCUS is never released!

 

If you click on the arrow of the combo-box it is all right. The events EVENT_GOT_FOCUS and EVENT_LOST_FOCUS are released. But the mouse click in the string field causes this strange behaviour.

 

If I understand it right, the combo-box control consists of two controls: the string control and the ring control. Could it be that these events from the string control are swallowed by the ring control?

 

Has anyone any suggestion?

 

Thanks in advance.

 

 

0 Kudos
Message 1 of 3
(3,156 Views)

I forgot to write that the combo-box controls are placed on the different panels.

So if you click first on the first combobox on the first panel and then on the second combox placed on the second panel, you get no LOST_FOCUS event for the first combobox.

 

0 Kudos
Message 2 of 3
(3,143 Views)

Hello Inomed,

 

to me this looks like expected behavior. You only recieve EVENT_LOST_FOCUS Events from controls from the active Panel. When you click on a different Panel, you recieve a EVENT_LOST_FOCUS Event from the Panel not from the Control. This happens with all Controls i tested so far. With the EVENT_GOT_FOCUS in the Control Callback and the EVENT_LOST_FOCUS in the Panel Callback you can implement the functionality.

 

Regards!

 

Moritz M.

0 Kudos
Message 3 of 3
(2,937 Views)