Script editor, window not open value error

Hi guys, I’m currently editing a property change for one of my buttons. I’d like its visibility to be defined by a component of another page.
So this button is on a docked “footer” page, that’s always open and opened at start up. and the component is a tab strip, that’s located in a docked “header” which is also always open & on start up.

on the script editor of property change, i have:

window = system.gui.getWindow("Header")
Tab = window.getRootContainer().getComponent("Main Tab Strip").selectedTab
if Tab == "OVERVIEW":
	value = 1
	event.source.visible = value

And the error I get when running it on vision is

ValueError: Window Header is not currently open.

HOwver its all opened at start up…im not sure how to go about this. thank you all

I would create a Vision Client Tag for the information that needs to be shared from the component on the header dock, and bind the button to that (or those) Client Tag to set the visibility.

Hi phil, thank you for pointing me in the right drection! I’ve just gone over client tags. but im not 100% sure on how to get about this way on attaching the visibility property to the client tag.

could you point us a bit more please? thank you!!