Jump to content
Server Maintenance This Week. ×

script for buttons that are fake tabs


This topic is 6570 days old. Please don't post here. Open a new topic instead.

Recommended Posts

I am attempting to "not use tabs" for the data entry layouts and just use "fake tabs" (from the majority of advice on another topic). I am having trouble, though, with the buttons for the fake tabs. My layout is for one person and has the First & Last name on top and then come the fake tabs/buttons. The first button is Personal, 2nd is Position Info, 3rd is Appointment and so on.... each fake tab will be another layout. (attached are screen shots to further clarify)

But when I am on John Smith and on the Personal tab, when I click the 2nd tab- Position Info, it moves to another name- like Jane Doe.

What would a script look like for the buttons so that they stay on the same person- so my user thinks these are real tabs?

screenshots.zip

Link to comment
Share on other sites

If you're going to another layout based on the same TO (table occurence) it will stay on the same record, but if you change TOs it could be a different record.

Generally, when switching among sub-tabs on a layout, the user expects to be in the same table. If the layouts are based on entirely different tables but are really meant to still be looking at the same person's data (like with a one-to-one relationship), then there may be a better structure. If the relationship between the tables is a one-to-many, then the tabs don't really make sense here either.

If you can explain you structure a little, a solution may become apparent.

Link to comment
Share on other sites

Embarrassed but true, I don't know much of TO and how to use them. I thought a simple relationship from people to jobs would do the trick.... is there any tutorial for beginners about TO's... I looked in my books and can't find any reference to Table Occurences. :)

Link to comment
Share on other sites

Attached is a screen shot of my relationships.... any advice you could provide is greatly appreciated!

I also posted another topic just asking for a review or advice on TO and if anyone can pick apart my relationship theory to make sure I am on the right track.. the topic is Post#203503 Seeking your advice (link) http://fmforums.com/forum/showtopic.php?tid/176247/post/203503/#203503/

relationships.jpg

Link to comment
Share on other sites

It sounds like that Jobs table is really a Job Assignment table--the Job a particular employee happens to be performing during a given date range. So since an Employee can have many Job_Assignments, it makes more sense to me to make the Jobs layout based on the Employee (People) table, and use a portal to show those multiple Job_Assignments. If you wish to allow a detail view for Job_Assignment use another layout, either one that leaves the tab interface, or one that shows the tabs (just be sure to have any navigation scripts incorporate Go to Related Records[] script step when changing base TOs).

Link to comment
Share on other sites

(just be sure to have any navigation scripts incorporate Go to Related Records[] script step when changing base TOs).

That is where I started trying... but am running into problems. Attached is a screen shot... I am trying to move from 1 fake tab to another fake tab all for the same person (but the fake tabs are buttons for other layouts) For example, find Joe Blow.... go to Personal Tab and fill out his address etc (that goes in People table)... then still under Joe Blow... go to Position Info (which really is job assignment- thank you for that) and fill out his base salary and hire date etc (which goes in the job table-related to People)... and so on and so on.

Can you help me with the script- what am I doing wrong?

screenshotsinword.zip

Link to comment
Share on other sites

Ok, new example attached (sign in as Admin, no password) with three tables: Personal, Position & Phone and three "fake" tabs with the same name. All three tabs go to different layouts from the SAME table... Personal.

Notice on the Personal Tab 2 Layout the fields are actually from the Position table.

on Personal Tab 3 there is a portal for phone numbers and using the "Show Related Phone #'s" button shows the related records in a new window on a layout from the Phone table.

MyDB2.zip

Link to comment
Share on other sites

This topic is 6570 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.