All the text_area fields on our forms have a button with it the user can add a Timestamp to the text_area. We also want the user to be able to add that timestamp using a keyboard short cut (Ctrl-T), but only in the text_area that has focus.
My setTimeStamp function needs the active form and active element, any suggestions how I can get those values from the global function that is linked to my shortcut?
On the form level there is a onFocusGained and onFocusLost method. In the onFocusGained you can get the form and element name.
that’s what i’m doing now, i was hoping that there was a generic function/property so i wouldnt have to add those events to all my controls
jdbruijn:
to all my controls
Not sure if you got it from Sanneke’s post, but you don’t have to set it on all elements, you can do it at the form level.