Virtual List Portal Sidebar

The wonderful thing about FileMaker is this. If you don't know of a native way to make it happen, you just force the native tools to bend to your wishes to accomplish your goals.

Such is the case with using portals. While using a portal for something related to the UI, navigation for example, is nothing new, the notion of storing that navigation in something other than a table may be a bit foreign to some.

The crux of this technique is to use global variables in such a creative way as to avoid some of the short comings with using a dedicated table for facilitating solution wide navigation. If you've not used the Virtual list technique to render the contents of a global variable within a portal, then this technique provides the perfect excuse to learn. Pretty much every FileMaker solution needs to facilitate navigation.

Need icons in your sidebar? No problem.
Need toggle arrows? No problem.
Need integrated search features? Totally possible.

Watch this video for a good understanding of how to bend FileMaker portals to your every wish.

AttachmentSize
VirtualListPortalSidebar.zip110.47 KB

Comments

Interesting technique

Any thoughts on modifying this to work in Find Mode?

To be honest, I typically opt to control the way a user searches and I wouldn't necessarily plan on putting this feature in a solution where the default query-by-form is used.

Given that FileMaker's native Find mode anticipates heading into fields, you're not going to be able to have the global merge variables render in the portal.

The best case scenario is to creatively use conditional formatting for when the user enters into find mode. I would probably show some type of prompt that "navigation is not possible within find mode".

Hope that helps.

-- Matt Petrowsky - ISO FileMaker Magazine Editor

Hi Matt,

Great example on using Virtual List and use of portal refresh with (-out sort of) a carthesian join.

One localization issue however; the field type's on field's "data" and "menuName" in table "Sidebar" are calculation's where the result's are defined as "number".
In the startupScript "Technique Startup" you Set Use System Formats to [On]. This will result on non-US system's to evaluate the strings to globals like $$MENU,HOME (notice the comma instead of a dot). By setting the field types to result in text the solution can be used on metric system's as well!

Hey thanks for this find. I'll update this on my copy of the technique file.

-- Matt Petrowsky - ISO FileMaker Magazine Editor

Would this technique lend itself to adding another criteria when building the virtual list that would check to see if a particular user had access to a given layout first, and if the user didn't, skip that item in the virtual list? The vision would be to initially build a sidebar with all of the different roots and sub menus. Then in a preference layout of some sort, be able to check/uncheck which layouts a user would have access to, and when the sidebar is built any layout that is not authorized is simply skipped.

Just curious if this type of thing is even possible in FileMaker, and if so, how cumbersome it would be to extend this technique to allow for it.

Yes, you certainly can limit what is built for the sidebar. This can be done based on FileMaker's built in permissions or your own set of permissions or user groupings on top of your solution.

I'll have to look into adding this feature into the file in the future. Just a bit busy now - but, at least you know it's possible!

-- Matt Petrowsky - ISO FileMaker Magazine Editor

I can only imagine how busy you are :) If there's a demo some day of that, great, but no rush on my account. Just knowing that it is possible is enough for me to pursue it on my own.

Thanks!

I am trying to use this (really cool) menu method in a "large" database (lots of menu options).
When I create a ROOT menu with nine (9) options or more things get a bit strange...9 gives me 90 portal rows...20 gives me 2.
I cannot locate the problem. Any assistance would be greatly appreciated.

Hey Bill,

Unfortunately, I've got so many things going on it's hard to invest the time in troubleshooting. Maybe, if you have a local FileMaker users's group you could have someone take a look.

Most problems that happen with tweaking the files I provide are that the tech is either updated, think newer versions of FileMaker or updated plug-ins, or it's a setting somewhere in the logic which has been over looked.

One nice thing about the technique files is that you can always trash the one you've got and then rewatch the video and try implementing on a newer copy of the file.

Try making the changes in the technique file first and then try implementing into your own files.

Time will usually solve the problem. :)

Matt

-- Matt Petrowsky - ISO FileMaker Magazine Editor

Matt,
Busy is good! Try to stay that way!

After several unsuccessful attempts to make this work, it finally occurred to me that assigned variables are not necessarily numbers.
In your exit loop code: "Let ( $i = $i + 1 ; If ( $i > $itemCount ; Let ( $i = "" ; True ) ) " $itemCount contained the correct value but not as a number.
I changed it to "Let ( $i = $i + 1 ; If ( $i > Int ($itemCount) ; Let ( $i = "" ; True ) ) )" (in both sections where it was used) and now all values work well and I can create my outrageously large number of menu choices.

This would have been a great file to use for the debugging video.
Everything displayed in debug and the data viewer correctly but did not evaluate correctly.
I guess you can't always believe everything you see.

Even including the evaluation issue this is an awesome menu display system.
Thanks and keep them coming. ;)
Bill

hey matt! how can I chose my own icons? bit confused about where they are stored as the icons field is global. thanks!

Islay Leefe-Griffiths