Hi all,
I have a MainForm [Main Page]. This main form has a SubForm [SubformA]. SubformA has 7 subforms [Sections A-G].
I am trying to determine when each of those 3rd level subform(the childs) have focus.
I have tried both lines below on the Form Current Event of the Child(section) subforms:
See screen shot below.
My objective here is to make the "Go To Section Toggle button" (see bottom if form) the highlighted button when a particular child form has the focus. So for example if Section "C" has the fucus, I want the button labeled "C" to be the active button at the bottom of the form.
How can I tell which child has the focus?
thanks in advance
Ed
PS I have tried couple of suggestions I found across the net but none of them worked so far.
I have a MainForm [Main Page]. This main form has a SubForm [SubformA]. SubformA has 7 subforms [Sections A-G].
I am trying to determine when each of those 3rd level subform(the childs) have focus.
I have tried both lines below on the Form Current Event of the Child(section) subforms:
Code:
[indent]'1)Screen.ActiveForm.Name 'This return the main form name [Main Page][/indent]
[indent]'2)Screen.ActiveForm.ActiveControl.Name 'This return the Second Level form [SubformA][/indent]
If Screen.ActiveForm.ActiveControl.Name = Me.Name Then
Forms![Main Page]![SubformA].Form.SectionSelect.value = 1 'if Section A has fucus
'Forms![Main Page]![SubformA].Form.SectionSelect.value = 2 'if Section B has fucus
End If
See screen shot below.
My objective here is to make the "Go To Section Toggle button" (see bottom if form) the highlighted button when a particular child form has the focus. So for example if Section "C" has the fucus, I want the button labeled "C" to be the active button at the bottom of the form.
How can I tell which child has the focus?
thanks in advance
Ed
PS I have tried couple of suggestions I found across the net but none of them worked so far.