I have a several paged tab control on my form.
On each page, there are several different controls. One page may have
5 controls and the other may have 10.
Can I run specific code when one of those controls on a particular page
is clicked.
I dont have to have to put code in each controls on click event and the
Tabs Click event only fires when you click "outside" of the actual
control and somewherre on a blank part of the tab page.
Basically - I've placed a bunch of text boxes (with a flat effect) to
make them look like command buttons. Then when a user selects the
control - I want the background of the selected control to turn a
different colors to show its been selected. Ofcourse the code would
have to cycle through the rest of the controls to make sure that the
other "command buttons" are set to the unselected color.
I know option boxes would be a lot easier - but I am trying something a
little different.
Thanks,
Brian
> Can I run specific code when one of those controls on a particular page
> is clicked.
Use the tab on change event. Each page in a tab control has a page
index property value, which is on the format tab of the page properties
window. I use it like this:
Private Sub tabWo_Change()
'If value is 9 (the advanced custom page), run the following afterupdate
event to get the rowsource for the list box
If Me.tabWo.Value = 9 Then
Me.subAdv.Form.fraOraClause_AfterUpdate
End If
End Sub
You may be able to do it by referring to other properties, but the above
works fine for me.

Signature
Tim http://www.ucs.mun.ca/~tmarshal/
^o<
/#) "Burp-beep, burp-beep, burp-beep?" - Quaker Jake
/^^ "Whatcha doin?" - Ditto "TIM-MAY!!" - Me