Need Tab Control Advice

R

Rich Locus

Access Members:
I have programmed events for regular forms, but never before have I tried to
use the tab control to house multiple forms. (Paradox: The Form Contains the
Tab Control, and I want the Tab Control to Contain the Actual Data Entry
Form).

My objective is to have "Page 1" on the tab be a form to enter business
contact information from Table1. "Page 2" in the tab control will be used to
enter personal information in Table2. And I will have several other tabs
that would house other forms to access other tables.

First of all, it didn't seem like I could use a Wizard to generate a form
within the tab control, so am I looking at hand-coding every text box and
setting the record source manually? Also, how does one address an object:
FormName!TabControlName!PageName!InnerFormName!txtBoxName?

Which would be better: Access 2003 or 2007 for this feature?

Thanks in advance.
 
R

Rich Locus

Tighe:
Thanks... that's a good start.
--
Rich Locus
Logicwurks, LLC


tighe said:
Rich,

i have only used 2007, so i know for tabbed pages if you drag a table into
the tab it will wizard a form for you. of course if you already have main
forms that you want to be the subforms, don't do that, just drag them into
the tab. as for the reference
Forms![MainFormNAme]![NameOftabPage].Form![Label2]

the Name of Tab Page is important, it is not the name of the source form on
the tab.

i would recommend looking around further on tabs especially when to load
data etc., there are lots of fun things you can do with them.

Rich Locus said:
Access Members:
I have programmed events for regular forms, but never before have I tried to
use the tab control to house multiple forms. (Paradox: The Form Contains the
Tab Control, and I want the Tab Control to Contain the Actual Data Entry
Form).

My objective is to have "Page 1" on the tab be a form to enter business
contact information from Table1. "Page 2" in the tab control will be used to
enter personal information in Table2. And I will have several other tabs
that would house other forms to access other tables.

First of all, it didn't seem like I could use a Wizard to generate a form
within the tab control, so am I looking at hand-coding every text box and
setting the record source manually? Also, how does one address an object:
FormName!TabControlName!PageName!InnerFormName!txtBoxName?

Which would be better: Access 2003 or 2007 for this feature?

Thanks in advance.
 
D

Dirk Goldgar

Rich Locus said:
Access Members:
I have programmed events for regular forms, but never before have I tried
to
use the tab control to house multiple forms. (Paradox: The Form Contains
the
Tab Control, and I want the Tab Control to Contain the Actual Data Entry
Form).

My objective is to have "Page 1" on the tab be a form to enter business
contact information from Table1. "Page 2" in the tab control will be used
to
enter personal information in Table2. And I will have several other tabs
that would house other forms to access other tables.

First of all, it didn't seem like I could use a Wizard to generate a form
within the tab control, so am I looking at hand-coding every text box and
setting the record source manually?

This is a lot easier than you may think. The key is to put a different
subform on each page of the tab control. You create the subforms
separately, as independent form objects, and then drag and drop each one
onto the appropriate page of the tab control in design view. That creates a
subform control on the tab page that has the form you created as its Source
Object.

Note: in doing this, it's important that you make sure you drop the subform
onto the tab page, not onto the detail section of the form behind the tab
page. You should get some visual feedback as you drag the form over the tab
page to show that you are dropping onto that page.

If the subforms need to be related to the main form's record in some way,
you use the Link Master Fields and Link Child Fields properties of each
subform control to do it. You may want to read the help topics about
subforms, if you aren't familiar with houw they work.
Also, how does one address an object:
FormName!TabControlName!PageName!InnerFormName!txtBoxName?

The tab control is irrelevant in the referencing scheme, so you do this:

Forms!MainFormName!SubformControlName!txtBoxName

Note that it's the name of the subform *control* (on the main form) that
must be used, which may or may not be the name of the form that is its
Source Object.
Which would be better: Access 2003 or 2007 for this feature?

Makes no difference.
 

Ask a Question

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.

Ask a Question

Top