D
DAACKM
I am attempting to service several Excel controls from the same macro code as
shown below:
Sub WHOAMI()
Dim ctrl As Control
Dim getactivectlname, mytext
ctrl = screen.ActiveControl
mytext = ctrl.Name
MsgBox ("The Value Is " & ctrl & " text= " & mytext & " thats all")
End Sub
WHOAMI launches, but on the "CTRL = SCREEN.ACTIVECONTROL" statement I get a
"Runtime Error 424 -- Object Required" error.
This is on Excel XP (2002). Any Ideas? Currently I have no DECLARATIONS.
Thanks for the help. Dave
shown below:
Sub WHOAMI()
Dim ctrl As Control
Dim getactivectlname, mytext
ctrl = screen.ActiveControl
mytext = ctrl.Name
MsgBox ("The Value Is " & ctrl & " text= " & mytext & " thats all")
End Sub
WHOAMI launches, but on the "CTRL = SCREEN.ACTIVECONTROL" statement I get a
"Runtime Error 424 -- Object Required" error.
This is on Excel XP (2002). Any Ideas? Currently I have no DECLARATIONS.
Thanks for the help. Dave