Highlighted

Master Page button hidden prob

Avatar

08-01-2009

How can i make a button in a masterpage invisble??



The code should run from a Script Object.



Hierarchy is ::



testForm

MasterPage

Page1

resetButton

MainPage

Variables

MyScripts



MyScripts is a script object..



And i want to make the resetButton in MasterPage invisible depending on some conditions.

Replies

Highlighted

Avatar

Avatar

Thomas_McConnac

Avatar

Thomas_McConnac

Thomas_McConnac

09-01-2009

resetButton.presence = "invisible";
Highlighted

Avatar

09-01-2009

thanks for the reply. But this is not working. coz i need to access the button of the master page from subpage.



i even tried

xfa.form.testForm.Masterpage.page1.resetbutton.presence = "invisible"



and even xfa.resolvenode("xfa....resetButton").presence = "invisible"



but none of them are working..



Any other idea??
Highlighted

Avatar

Avatar

pguerett

Total Posts

7.7K

Likes

611

Correct Answer

692

Avatar

pguerett

Total Posts

7.7K

Likes

611

Correct Answer

692
pguerett

09-01-2009

The Master page objects are under a PageSet node. So assuming that your button is on a masterpage called Page1 the expression would be:



form1.pageSet.Page1.Button1



To verify you can always put this javascript command on the click of the button to validate how to get to the object:



app.alert(this.somExpression)