J
John S
Back again (can't stay away)
I was having a problem clearing a subform, which I have resolved by the
revelation that a subform is NOT a part of the forms collection, rather it
is a control on a form. But this control also has controls that can be
referenced. For example, I reference (to clear) my subform controls from
the main form thus:
[sfPet].Form.txt2003.Value = ""
Is is possible to cycle through all the subform controls, or must I
reference each by actual control name?
Second question / observation. After clearing each subform control, I wanted
to return to the first field in the main form. Didn't work: always tried to
go to the first field in the subform. On a pure hunch, I tried first
returning the focus to the main form, and then setting the focus on the
first field in the main form. Worked! Any idea why?
Perpetually Intrigued
J. Smith
Aylmer, PQ
I was having a problem clearing a subform, which I have resolved by the
revelation that a subform is NOT a part of the forms collection, rather it
is a control on a form. But this control also has controls that can be
referenced. For example, I reference (to clear) my subform controls from
the main form thus:
[sfPet].Form.txt2003.Value = ""
Is is possible to cycle through all the subform controls, or must I
reference each by actual control name?
Second question / observation. After clearing each subform control, I wanted
to return to the first field in the main form. Didn't work: always tried to
go to the first field in the subform. On a pure hunch, I tried first
returning the focus to the main form, and then setting the focus on the
first field in the main form. Worked! Any idea why?
Perpetually Intrigued
J. Smith
Aylmer, PQ