Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Find name of control

Status
Not open for further replies.

dendic

Programmer
Jan 19, 2003
106
US
On my form I have a label named Test1. On double click I'm running code. Is there a method to get the name of the control that initiated the call. Or is there a way to get the name of the code running. Because the sub name has the name of the contol embedded example: sub test1_DoubleClick.
 
It is not so easy with a label. If the control can receive focus, you can use Screen.ActiveControl.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top