I have many labels in my form. What I wanna do is when I click on the label, a msgbox displaying its name will come up. I used to use screen.activecontrol (see below for code) when I want to display a textbox name, but it seems it does not work for label. Does anyone know how to achieve this ?
I think label has several event procedures such Onclick and OnDoubleClick. The thing is I have more than 100 labels, so if someone clicks on it and wanna change the caption, it's much easier for me to create a general function that captures which label the user clicks rather than create a specific procedure for each label OnClick event. Do you have any idea how to get around this problem ?