Jump to content
jdu98a

[Samples] NavSystem

Recommended Posts

index.php?app=downloads&module=display&s

File Name: NavSystem

File Submitter: jdu98a

File Submitted: 07 Sep 2011

File Updated: 06 Oct 2011

File Category: Samples

FM Version: 11

I wanted to see how far I could take the idea of using global repeating container fields to store layout objects, specifically for navigation buttons. This is what I came up with.

All image and text values that are displayed on the layout for navigation are stored in an "Objects" table. The benefit of this is that any layout that has the needed global repeating fields on it will display the same navigation buttons and text. Want to add more buttons? Just go to the Objects layout (click the grey globe button at the bottom left) and import an image or input new text values. The new option will automatically be added to all layouts.

What I really like about it is that everything is controlled by two simple scripts. "Main Navigation" and "Sub Navigation". And all they do is modify one of two global fields. Of course more script steps are needed to actually perform layout navigation or other jobs. I've included the structure that would be needed to facilitate that already in the scripts as you will see.

I've seen examples of this in a limited fashion, but like I said, I wanted to see how far I could take it. Thanks for any feedback or advice that you can offer.

Click here to download this file

Share this post


Link to post
Share on other sites

Looks great, I tore it apart, but was so many if , elses, calculations, just to get everything working.

Why not when starting up . just load all the globals using a startup script & not worry about the MAINNAV< COnnecting to the SUBNAV< CONNecting to the SUBNAV_IMAGE. DUDE .

It is alot.

but again. i am learning so what do i know.

Since i have looked at your file, i haev been trying to understand extend .. Still havent figured it out, but looks like something i def. need to learn

-i

Share this post


Link to post
Share on other sites

Thanks for the insight. It is possible that it the whole thing could be simplified. Part of the complexity in setting it up is to allow for the easy modification later on. Do the work once instead of over and over kind of mindset. But that being said I have no doubt that things could be streamlined. Maybe in a future version I will have found some ways to do that.

Another reason for the complexity is the fact that all the images are constantly changing. You could load an initial set of images using the startup script, but the first time you click one they need to change to reflect your new selection. That kind of functionality requires more structure.

The Extend function should be thought of like this: any time you need to apply the contents of a non-repeating field to every repetition of a repeating one, the non-repeating field needs to be expressed within the Extend function. So in the case of my sample there are several instances where I need each repetition of a repeating field to return its own unique result to a calculation based on the state of some non-repeating field. So I use the Extend function.

Share this post


Link to post
Share on other sites

Ok, So I am hoping that I might get an answer on this VERY OLD thread.  I downloaded this menu system and I absolutely love it.  Just one issue.  I merged it into my existing project and I have everything working except one extremely critical item.  When I go into the globals setup layout and I add or change anything I can not get it to save to the @ GLobals table.  I have tried everything and I can't get anything to save to that table.  The demo file works perfectly including the ability to save changes to @Global.  I am banging my head against the wall on this simple thing.  Anyone willing to help on this really old item by pointing me in another direction I might have overlooked.

 

Thanks,


Rob

Share this post


Link to post
Share on other sites

Thanks for the advice.  I reached out to Daniel and your right a more current solution would be a better choice. 

 

Rob

Share this post


Link to post
Share on other sites

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


×

Important Information

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