-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Put a parameter in the Sub and in the call. E.g.:
Frm.Controls("Label" & ii).OnClick = "=Event_Click(" & ii & ")"
Sub Event_Click(bytLabelID As Byte)
Select Case bytLabelID
Case 1
' do something
Case 2
' do something else
' ... etc. ...
End Select
End Sub
--
MGFoster:::mgf00 <at> earthlink <decimal-point> net
Oakland, CA (USA)
-----BEGIN PGP SIGNATURE-----
Version: PGP for Personal Privacy 5.0
Charset: noconv
iQA/AwUBQlrVRYechKqOuFEgEQL2xwCgsB2oAXQhHAdF8xyDyJDXiG 8YsuUAn144
r3cmG8XaL42Z0w7aEfq/mKDR
=Hxoh
-----END PGP SIGNATURE-----
Luca Giannoni wrote:
Hi to everybody,
I have this problem
I attach an event to a group of control from code:
Set Frm = Fom_Test
for ii = 1 to 100
Frm.Controls("Label" & ii).OnClick = "=Event_Click()"
Next
Event_Click() is on form Form_Test
Sub Event_Click()
' code to apply to label caller
End Sub
when the event "raise" I need to know wich object (label) call the event.
Someone could help me?
thanks in advance
Luca