LabVIEW Idea Exchange

cancel
Showing results for 
Search instead for 
Did you mean: 
GerdW

Key focus Event

Status: New

Hi,

 

i propose to add a "Key Focus" event for each control. We already have Mouse events (leaving, entering) - but when the user (or the programmer) prefers the keyboard (with proper tabbing setup) you have to poll each interesting control for it's "Key Focus" property to initiate a user event...

 

So please:

Add a "Got Focus" (and additionally a "Lost Focus") event to the event structure!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
16 Comments
AristosQueue (NI)
NI Employee (retired)

If we do this, please make sure that the data portion of "Got Focus" includes information about what control had it previously so that you can tell whether the user hit TAB or shift+TAB in case you're trying to forward the focus along (say a cluster forwarding to its contents).

SteveChandler
Trusted Enthusiast

There are lots of events that should be added. Events in LabVIEW are pretty limited compared to something like Windows Forms.

 

Some others: Ring or enum dropdown or collapse (before and after), panel loaded, panel visible, minimized, tree node before expand, after expand... I am sure I could come up with more.

=====================
LabVIEW 2012


silmaril
Member

Yes! The got/lost focus events are definitively the ones I am missing most!

 

Not having them leads to very unelegant code, in which I have to check the KeyFocus property of a large list of controls every few milliseconds.

 

Maybe we could also have an event "Panel:Focus Change"?

This would be triggered whenever any focus change on a panel occures (and of course it should contain control references to the controls that just lost and got the focus).

 

WG-
Member
Member

This should definitly be implemented in LV 2013.

Intaris
Proven Zealot

And it would be cool if this and almost all other events were bidirectional allowing fcar more custom UI functionality.

Romain_Duval
Active Participant

Definitely +1 for the panel:focus changed event.

Romain DUVAL || RF & Semiconductor Staff System Engineer || CLA || CTA
National Instruments France

SL13
Member

hi,

yes a focus event would be very convenient. +1 for this idea

MinerHokieRamp
Member

I spent a lot of time searching the forum on how to do this and landed here. I don't see this feature in LV2013.

Jeffrey Bledsoe
Electrical Engineer
PeppeJeppe
Member

Like everyone else I ended up here. Please add it!! It takes to much execution time to poll the focus property.

PeppeJeppe
Member

I'm blind because I cant find where to click to give it kudos 😉