Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
louiswinter
Partner - Creator
Partner - Creator

Menu Extension Link Issues

We need a dropdown menu for our app and I found the drop down menu document extension that looks very promising.  After installing the extension and updating the Title and condition logic on all of my sheets, the menu works just fine.  The issue we have is that some of our .qvw files have 40+ sheets that will become menu options.  Adding the %parentSheetId=XXXXX% information to all of these sheets causes the tabrow to take up too much screen space than we like (6-8+ rows of sheets) while editing in the desktop.  I want to come up with a better solution than putting the extra information in the sheet name.

For a solution my thought was to load a spreadsheet with the extra information (Title, Sheet ID, Parent Sheet ID, and Is Link fields) instead of in the sheet title, then load it into the .qvw and put it into a table on a sheet that will not be displayed.  The SetTabrowPaint function could then find my menu table object, match up the Title with the tab data, and build the html accordingly.

I ran into a couple issues.  If I look for the table object in the SetTabrowPaint function it finds it, but the data isn't loaded yet.  I then split the SetTabrowPaint function into 2.  The first function creates the <nav>, <div>, and main <ul> tags and sets a SetOnUpdateComplete callback function on the menu table object.  The callback function then finds the <ul> and builds the menu based on the information in the menu table object.  This worked correctly and I am able to build the menu and it looks exactly the same.  The issue now is that the links don't work.  The .innerHTML, .onclick, and .Action properties of the menu items contain the exact same values as when they were created directly in the SetTabrowPaint function, they just don't work.

Any thoughts on why the links don't work?  Does the QV logic that calls the SetTabrowPaint function do something after the function completes?

0 Replies