Its 2 lines of scripting!

myPanel.visible = on/off; wherever you make your view visible/invisible.