joaocarlo Posted August 31, 2005 Posted August 31, 2005 I try FM8 and… hummmm Goto Layout A Goto Tab A or B, or C … or C It is possible scripting that?
Ender Posted August 31, 2005 Posted August 31, 2005 Looks like you'll need to use a Go to Field[] script step to get to the right tab.
joaocarlo Posted August 31, 2005 Author Posted August 31, 2005 I know that, but i think is not the same thing… the problem is: In case of the field A exists in all TABs? who scripting that without create empty fields?
Ender Posted August 31, 2005 Posted August 31, 2005 So don't use field A. Hopefully your tabs don't all have the same fields!
comment Posted August 31, 2005 Posted August 31, 2005 Pick a field that does NOT exist in all tabs. If your tabs have identical content, what do you need them for? Ender's suggestion is the official version - as stated in the Help file.
xochi Posted August 31, 2005 Posted August 31, 2005 (edited) This seems like bad object-oriented design. You should be able to navigate to a tab object based on it's ID, not the identity of what it holds... I can imagine cases where you'd have multiple tabs all containing the same fields. For example, if you were using a tabbed design to switch between view and edit modes -- you'd have the same fields on both tabs, but in one case they'd be editable and in the other case, view only. I can also see how this could make scripting difficult -- if you have a script that switches tabs, that script shouldn't have to know what fields are on the tab. This just encourages poor design. Not a big deal, but one of those little details which makes maintaining a filemaker database more difficult... EDIT: i suppose an advantage is that it's backwards-compatible somewhat with FM7, but still I'm not sure that's worth it for the compromise... Edited August 31, 2005 by Guest
comment Posted August 31, 2005 Posted August 31, 2005 The same bad object-oriented design does not allow assigning different access privileges to each tab - so it evens out.
Zero Tolerence Posted August 31, 2005 Posted August 31, 2005 Use repeating fields. Create a bogus field, gvar1, set it to repeat to the number of tabs you have. Use Go To Field, with repitition set on whatever tab you want to go to. Lock the field out, however you want, for this example I just made the point size 6, and have "go to next field" after i hit it. Of course this doesn't work, because I only have one field on the layout, but you get the idea. Notice on tab 5 that my field is extremely small in the top left hand corner of the tab. There is a way to get the current tab, but I haven't used Repeating fields enough to know how to do it. I assume it has something to do with get repitition count of the field, but I'm not sure. TabNav.zip
xochi Posted August 31, 2005 Posted August 31, 2005 It looks like you can't associate a script with a tab panel, either... this is too bad -- it would be really handy to have a script run when the user switches tabs (before the switch actually happens) -- you could then do permissions checking and switch them back to the other tab if they aren't allowed... Sigh.. So close to being what i want, but just not quite there. FileMaker 8 -- the big tease :
Zero Tolerence Posted August 31, 2005 Posted August 31, 2005 Yes, you can, just not by what filemaker does by itself, you have to help it. you see, you can make your tab names " ", and then put a field, or a graphic on the tab itself. Go to the specified tab like in my example above, and then call your script. I'll post an example in a bit.
Zero Tolerence Posted August 31, 2005 Posted August 31, 2005 (edited) Here you go. I am calling a script for each tab that is selected. I also have manually changed the text format for the selected tab to make it color, I'm sure there is an easier way to do this, but I haven't figured it out yet. However, I am changing tabs with 1 script every time. The script is called by clicking on the tab. I used Portals as my tab headers/buttons. Just a portal from a navigation table. 5 of them (For the 5 tabs) each showing one record (which record goes up every time. When the click on the field that is over the actual tab, it changes the tab and runs the script. TabNav.zip Edited August 31, 2005 by Guest
raymanj Posted September 1, 2005 Posted September 1, 2005 Has anyone done some testing with the TAB control were you may have one or more portals on each tab and all the portals contain large amounts or records. Is the data of all the portal's pulled at the same time when the layout is displayed or are they pulled when you click on the individual tabs? If they are loaded at the same time this could cause some slowdown when viewing layouts that may have a lot of tabs.
raymanj Posted September 2, 2005 Posted September 2, 2005 I can see how to go to a tab on a tab control via script, but what if I need to know what tab number the user is on when they click a button outside the tab control. Has anyone figured a way to do this?
Ugo DI LUCA Posted September 2, 2005 Posted September 2, 2005 May be by setting its original value in some global variable field as soon as he gets in
comment Posted September 3, 2005 Posted September 3, 2005 When the click on the field that is over the actual tab, it changes the tab and runs the script. I have looked at your file, to see if that is true. Because I found that if a button is placed inside a tab, the first click merely switches the tab panel, and does NOT activate the button. Only AFTER the tab panel has become active, you can click on the button. That is how your file behaves here, too.
comment Posted September 3, 2005 Posted September 3, 2005 May be by setting its original value in some global variable field as soon as he gets in I don't see a way of doing that - see above.
Ocean West Posted September 3, 2005 Posted September 3, 2005 Tab controlled interface is a SPACE SAVING feature. This allows you to reduce layouts in order to maximize screen real estate in order to fit all your information on to one layout. If your solution requires navigation/validation and other interface requirements it is recommended that you use established community techniques.
Brudderman Posted September 4, 2005 Posted September 4, 2005 If your solution requires navigation/validation and other interface requirements it is recommended that you use established community techniques. Does this mean that the recommended way to navigate from layout to layout is the same as before? That is, create a set of graphics for tabs and navigate by scripts? Or is there a simple way to employ the new tab panel to do that, too? You may do this when leaving the layout or when accessing the Layout, although, as you pointed, there is no other controls on the Tabs, thus moving from one Tab to another...
Ugo DI LUCA Posted September 4, 2005 Posted September 4, 2005 (edited) Hi Mike, Question was : "I need to know what tab number the user is on when they click a button outside the tab control." If it is outside the Tab Control, and if you use that repeating global field splitted in each Tab Layer, then you can use a loop involving Next Field and stop the loop when Get ( ActiveFieldName ) = "globalRep", then capture its content... A GoToField wouldn't work, a loop through the tabbed field, although not esthetic would. As for the Tab scripting itself, why would you like absolutely to put the button on to the Tabs themselves ? Test Edited September 4, 2005 by Guest
comment Posted September 4, 2005 Posted September 4, 2005 Yes, I see what you mean. But if the user happens to be in a field, you should also try and take him/her back there. This is all too clumsy for my taste. I believe Stephen is right: you should not treat tab control panels as separate layouts. The question 'in which tab panel am I' is the same as "am I now in the top half of the layout or the bottom one'.
Ugo DI LUCA Posted September 5, 2005 Posted September 5, 2005 (edited) Here's a small example of scripted Tabs, while in fact it looses a bit of the natural Tabbing capabilities offered by 8. TabScript.fp7.zip Edited September 18, 2005 by Guest Changed Open script and Open access to the Layouts where Repetition Trick is revealed
Zero Tolerence Posted September 6, 2005 Posted September 6, 2005 I have looked at your file, to see if that is true. Because I found that if a button is placed inside a tab, the first click merely switches the tab panel, and does NOT activate the button. Only AFTER the tab panel has become active, you can click on the button. That is how your file behaves here, too. Ahh yes, I see what your saying, and notice that you are correct. In my excitment I must have dropped the ball here, sorry all.
Tony O Posted September 12, 2005 Posted September 12, 2005 (edited) I know that, but i think is not the same thing… the problem is: In case of the field A exists in all TABs? who scripting that without create empty fields? Make one-to-one relationships for a field that exists on all tabs. Then when you use GoToField step, specify that field with it's corresponding relationship. See Example - it's fast and dirty but it works. I'm thinking of using similar techniques to direct users to different tabs in the record based on their department (ie sales to the Sales spec tab, Creative to the time tracker tab, shipping to shipping etc). In my case, there are relationships between all of those that refer to a common field, so it's pretty much cake. hth, Tony Tab_Sample.fp7.zip Edited September 12, 2005 by Guest
titanium76 Posted October 5, 2005 Posted October 5, 2005 But why? I find all these solutions, honestly - stupid. FileMaker 8.01 should have a fix for both Tab scripting and calculated naming. This is such a hot topic, I can not believe the geniuses at FileMaker missed this one. How can it possibly be such a robust cross-platform product with such a MAJOR oversight? Bizarre... Anyway, I must agree with the others who recommend NOT using a hair-brained trick to make it work. Eventually you will encounter a problem or simply have a poor design.
Matt Klein Posted October 7, 2005 Posted October 7, 2005 This is a little off topic, but Ugo where do you get your icons from?
mr_vodka Posted October 7, 2005 Posted October 7, 2005 Haha. I just saked him the same question to him the other day privately. Ugo stated: "Take a look at Iconexperience.com where I purchased them."
Matt Klein Posted October 7, 2005 Posted October 7, 2005 Haha. I just saked him the same question to him the other day privately. Ugo stated: "Take a look at Iconexperience.com where I purchased them." Thanks!! That's great!
Utopian Posted November 22, 2005 Posted November 22, 2005 But why? I find all these solutions, honestly - stupid. FileMaker 8.01 should have a fix for both Tab scripting and calculated naming. This is such a hot topic, I can not believe the geniuses at FileMaker missed this one. How can it possibly be such a robust cross-platform product with such a MAJOR oversight? Bizarre... I can't help but agree. It is utterly moronic that I have to script ANYTHING to simply navigate back to the tab I was looking at when I left a layout and then came back. No doubt this will end up being one of FMP 9's chargeable "features". :
DLS Posted November 26, 2005 Posted November 26, 2005 Yup. The Tab Interface a nice slice of pie but it's small and half baked...
SteveB Posted November 26, 2005 Posted November 26, 2005 A lot of what Filemaker does starts out as half-baked, and I do love to complain about them. However, version 8 is a super improvement over things past. Its not perfect, and version 9 surely won't be. No software product is perfect, nor will it suit everybody. Steve
Recommended Posts
This topic is 7028 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 accountSign in
Already have an account? Sign in here.
Sign In Now