Tab strip navigation

I’ve noticed that many times randomly when I try to swap window navigate from one window to another, sometimes I click and nothing happens. I try again, nothing… If i click a different window and then try the original one, it works (sometimes).
I’ve looked at the navigation several times scratching my head trying to figure out why it doesn’t work every time.
Here’s what I noticed… The windows that I can remember not working all the time have longer pathname.
I have them in a folder, so the navigation points to the correct window, but perhaps there is a problem associated with this level of path direction.

This is usually because you have multiple “main” windows. Look in the client menubar under the “Windows” item for a list of the currently open windows. If you have more than one that is Floating (not docked) and maximized, then Ignition cannot tell which one to swap.

When you open windows with a button, use the system.nav.swapTo() function for your maximized windows and system.nav.open() for the popup windows.

1 Like

if I use a navigation on a button which is on a popup…
My main window could be different… how can I reference the main window I’m in without knowing what it’s called… is there a something.lookup.currentmainwindow?

There is a System tag that always holds your current main window. Most people bind the Tab Strip’s selectedTab property to it. You can find it at:
[System]Client/User/CurrentWindow

Note: In the designer, it will always be an empty string.

1 Like

[quote=“Robert.McKenzie”]There is a System tag that always holds your current main window. Most people bind the Tab Strip’s selectedTab property to it. You can find it at:
[System]Client/User/CurrentWindow

Note: In the designer, it will always be an empty string.[/quote]

Thanks, I can see that this made a difference.
I haven’t had any problems since.