Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Dynamic Creation of Tabs in a Form?

Status
Not open for further replies.

kleda

MIS
Jun 21, 2004
4
US
Hello all,

Does anyone know if it is possible to dynamically multiple identical tabs in an Access form depending on a query? Let me explain what I'm trying to do to clarify:

Basically, I am attempting to create a database to track changes for assembly drawings. For each specific part number, I need to track a bunch of information for each change request - such as date change approved, requestor of change, etc. Each change request has a unique number. But I need to be able to keep a history of each change... So for each part number, I need to be able to pull up all of the past change requests and see all of the relevant information to that request.

My first thought was to use tabs in an Access form to do this: Have the part number at the very top, above the tabs. Then, depending on what part number was selected, the tabs would auto-populate - ex. the first tab title would change to be Change Request #4353 or whatever, the second Change Request #5443, and the rest of the information on each tab would auto-populate. The issue is that some part numbers will have just one change request #, and others will have ten. So I need a way to dynamically change the number of tabs on form....

I'm guessing that this might not be possible in Access.... Has anyone heard of this before? Any other ideas or other suggestions are much appreciated!

Thanks,
Dan
 
I have never heard of doing what you are trying to accompolish (that in itself may not mean much). Maybe others may have.
Suggestion:
You may want to use a sub form concept to keep track of the changes. In my experience and that of others having too many tabs can be a bigger pain. It can become cumberson.


HTH

An investment in knowledge always pays the best dividends.
by Benjamin Franklin
Autonumber Description - FAQ702-5106
 
Hi

Usual way to do this is to define "n" tabs, but set their visible property to false, then for as many as you need at the time set the visible property to true

Regards

Ken Reay
Freelance Solutions Developer
Boldon Information Systems Ltd
Website needs upgrading, but for now - UK
 
How are ya kleda . . . . .

[blue]KenReay[/blue] has a great solution. Bear in mind this also comes with a small positioning problem. As each tab is viewed, the position of common controls will have to be shifted to stay in relative positions to each tab. This is not hard to do, just additional coding.
kleda said:
[blue]I am attempting to create a database to track changes for assembly drawings[/blue]
For your purpose, I query using the Tab Control. Your [blue]tracking history[/blue], and need to see as many [blue]Change Request[/blue] as you can at one time! Since the Tab Control is hiding each individual [blue]Change Request[/blue], you would have go from tab to tab to parse its history.

Where as, a [purple]Continuous Form[/purple] would afford you maximum viewable [blue]Change Request History[/blue], with the ease of scrolling.

Where history is concerned, [purple]Continuous Forms[/purple] are usually the way to go . . . . .

Calvin.gif
See Ya! . . . . . .
 
Thank you all for your suggestions. KenReay had a cool suggestion for working around the dynamic tabs issue.

However, it sounds like the best way to create this is to just stick with a simple, continuous sub-form, as mph1 and TheAceMan1 suggested. I figured that the form would look much cleaner separated into multiple tabs, but it could end up causing problems down the road, and wouldn't be super-fun to code anyway!

Thanks again for your help,
Dan
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top