A
awsmitty
Can someone suggest a reference for the syntax when using tabs on a form?
Can someone suggest a reference for the syntax when using tabs on a form?
Can someone suggest a reference for the syntax when using tabs on a form?
I hope this helps. I have a form called frmControlSchedule.
frmControlSchedule has several tabs; one of them is labled Search_for_Grid.
The tab, Search_for_Grid has a subform called frmsubAllRouteData.
frmsubAllRouteData is a datasheet. I am trying to address anyone of several
fields within frmsubAllRouteData, one of which is B_BLK.
I have tried all types of variations on the following:
If Search_for_Grid.[frmsubAllRouteData].Form![B_BLK] < 99999 Then
I have moved the brackets around, with and without brackets, various
variations with ! and . I have swapped places with Search_for_Grid,
frmsubAllRouteData, and have included frmControlSchedule. I can’t get
anything to work. I assume that frmControlSchedule would be default and
could be left out regardless of the full syntax.
Again, hope this helps
John W. Vinson said:I hope this helps. I have a form called frmControlSchedule.
frmControlSchedule has several tabs; one of them is labled Search_for_Grid.
The tab, Search_for_Grid has a subform called frmsubAllRouteData.
frmsubAllRouteData is a datasheet. I am trying to address anyone of several
fields within frmsubAllRouteData, one of which is B_BLK.
I have tried all types of variations on the following:
If Search_for_Grid.[frmsubAllRouteData].Form![B_BLK] < 99999 Then
I have moved the brackets around, with and without brackets, various
variations with ! and . I have swapped places with Search_for_Grid,
frmsubAllRouteData, and have included frmControlSchedule. I can’t get
anything to work. I assume that frmControlSchedule would be default and
could be left out regardless of the full syntax.
Again, hope this helps
The Tab Control doesn't come into the control referencing syntax at all. It's
just a *visual* way of arranging controls on the screen, in effect. Controls
(including Subform Controls) are referenced in exactly the same way, whether
they're on a tab page or not.
Assuming that the Name property of the subform control on the tab page is
frmsubAllRouteData (note that the Subform Control, the container, may have a
name different than the name of the form object within that control), try
If Me!frmsubAllRouteData.Form![B_BLK] < 99999 Then
The Me! keyword just means "the form containing this code" -
frmControlSchedule in this instance. You can use either but Me! makes the code
easier to move from form to form.
Which brings me to another question. Let's say there is B_BLK on one tab,
as a control, and B_BLK on another tab. Seems to me they are in fact one and
the same. Change one, the other changes right along with it. Is that the
case?
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.