hidden button is the active control

@arnelgp Finally! an answer that helps. I was playing with this and you have just fleshed it out. Thank you so much!
 
I don't need to know the clickable button's size or location. I need to know the name of the field I'm occupying when I shortcut key the transparent button. It could be one of two options on each subform.
Yes I realise that but you could use a lookup table to get the value you want from each command button. Or just use a similar naming convention for buttons and field names e.g. FieldName and cmdFieldName.
 
Wasn't the same exact method mentioned in post #2? by @MajP
not exactly, post #2 code will fail, since he did not use Set
to save the activecontrol.
and i use public function.
 
then i give majpi the attribution to the the code i posted and everyone is happy without complain.
No, you enhanced it. :)
My point was the O/P complained about finally getting an answer from your post #20, when it was pretty much offered on the second post. :(
 
point granted.
Ms.ClaraBarton, don't celebrate early, post#2 is the correct answer, disregard my post.
 
I need to know the name of the field I'm occupying when I shortcut key the transparent button.
i think we are moving in circles. if you use the double click event of the control you want the answer placed into, you have a place to put code where you can reference the me.controlname and not have to use the screen.active.control - which as others have mentioned, is not totally reliable.

arnelgp's suggestion is probably the best option if you are insistent on not using the double click event of the control you want the answer placed into.
 

Users who are viewing this thread

Back
Top Bottom