Don't reload pages when switching tab in navigation bar

Hi all

When I switch between tabs in my navigation window, the windows seems to reload every time I want to go to another window. So the page is reloading again and it takes again some time to set up. When a client launches a project, I don’t want the different windows to reload every time and want to load them just one time at start up.

Is there a way to do this?
Thanks a lot!

This is possible as an alternative navigation strategy.

You can use buttons to navigate, or if you use tabs, you must disable the default navigation mode:

Afterwards, you can react on a button click or tab switch with a script. For tab strips, you need to react on the selectedTab change. When using buttons, every button will have it’s own event.

if event.propertyName == "selectedTab":
	system.nav.openWindow("whatever/root/path/" + event.source.selectedTab)

Please also check the documentation for these functions: system.nav.openWindow - Ignition User Manual 7.9 - Ignition Documentation

  • openWindow will open a window on top, or bring it to the front if it’s already open
  • openWindowInstance will always open a new window, even if it already exists (handy for popups, where you may need to see two the same popups of different machines).
  • swap* will close the current window, and open a new one.

Note that when using the openWindow* functions for main page navigation, you lose the standard Ignition functionality of goBack, goForward, getCurrentWindow etc. As Ignition no longer can keep track of what’s currently considered the main window.

1 Like

It’s far better to use swap instead of open for navigation pages. MAke sure that your pages are set to cache: