Persisting selection state in a master across multiple pages


I’ve been banging my head for a week on this, so time to ask for help.

I made a site with a left panel menu. The menu is a master, with one instance per page. When I click any menu item, and navigate to that page, I want the menu to show a visual indicator that corresponds to the page I’m on, while also turning the old selection off. Sounds simple, but I haven’t found any properties or scripts that let me achieve this - I tried many combinations of selection groups, global vars, executing scripts on master load as well as page load… got nothin’.

See the attached file for an example of what I mean. It seems like what I need is a way to insert a variable into a “Set isSelected of” statement, because when the master loads, it needs to know the value of the CurrentMenu variable in order to select the right item out of the radio group. But no can do.

Hope someone can help me out!

JonMenu that needs persistent selection.rp (80.0 KB)

The easiest way is probably to put your menu on a page and then show the rest of your pages in an inline frame next to it. Then when you click around the menu just change the page in the frame.


Here is what I do.

  1. Create the master, give a name to each element that is the menu item. I name them the same as the pages.
  2. Create “Selected state” formatting (I also do mouseover formatting as a nice to have).
  3. Create your pages - you should have the same number of pages as menu items (obviously)
  4. Give meaningful names to your pages
  5. In the master, assign links to your menu items so that on click they go to the right page.
  6. Drop your menu to your pages
  7. On each page, create an OnLoad event, where you set Selected to True of the appropriate Menu items, and to False to all the other ones.

May be a little time consuming, but simple to maintain and it works :slight_smile:Menu that needs persistent selection_fixed.rp (107.4 KB)

1 Like

Thanks, I had tried that but I really want to stay away from frames if possible. I’ll use it as a last resort. :slight_smile:

Hi Rajsca,

Thanks, but I’m also trying to avoid setting every item’s selected state to False in a script… I’m using Axure to build a shared pattern and widget library and so far I have over 40 pages, with more expected on a regular basis. Ugh!

Or maybe I could put all of the logic into a hidden rectangle and use the Move 0,0 trick… hmm.

In any case, thanks for your help! I appreciate your taking the time to modify my humble example. :slight_smile:


Check this out.

I put a Selection Group around the menu items (right click > Selection Group).
Then on the Page OnLoad even, you only setSelected to true on the right menu item.

A Selection Group works like radio buttons. When you select one, the other ones become deselected.

Menu that needs persistent selection_fixed2.rp (107.5 KB)


I’m a little embarrassed now… I was wayyyy overthinking this problem. Thank you for the more elegant solution.

I know it’s been answered but here’s one with a repeater menu. I wanted to take a stab at it. I think it’s pretty darn clean.

menu.rp (91.6 KB)

Page 1 has instructions

:slight_smile: Happy I could help.

jhelmers - Thanks for the prototype! It’s a nice solution too. Already made changes using rajcsa’s code, but if I get a few moments I’ll try it this way.