Note that there are some explanatory texts on larger screens.

plurals
  1. POupdating (enable/disable) buttons inside a <p:toolBar>
    text
    copied!<p>i have a <code>&lt;p:toolBar&gt;</code> that contains <code>&lt;p:commandButton&gt;</code><br> but this toolbar is not put in a form since i am using template<br> these buttons are executing methods from a managed bean<br> the methods are excuted correctly and they are updating a form<br> when i want to enable and disable buttons by clicking on one of them this is not working</p> <p>example :</p> <pre><code>&lt;p:layout id="layout"&gt; &lt;p:layoutUnit position="west"&gt; &lt;p:toolbar&gt; &lt;p:toolbarGroup align="left"&gt; &lt;p:commandButton type="button" value="New" icon="ui-icon-document" /&gt; &lt;p:commandButton type="button" value="Open" actionListener="#{bean.anyMethod}" update="frm"/&gt; &lt;/p:toolbarGroup&gt; &lt;/p:toolbar&gt; &lt;/p:layoutUnit&gt; &lt;p:layoutUnit position="center"&gt; &lt;h:form id="frm"&gt; contents of h:form &lt;p:inputText&gt; and &lt;p:outputText&gt; componenets &lt;/h:form&gt; &lt;/p:layoutUnit&gt; &lt;/p:layout&gt; </code></pre> <p>my problem is that my <code>&lt;p:toolbar&gt;</code> is not in a form and when clicking the <strong>open button</strong> the <strong>actionListener</strong> is working and the <code>&lt;h:form id="frm"&gt;</code> is updated<br> but if i want the <strong>new button</strong> when clicked to enable/disable <strong>open button</strong> that is not working and i cant put the <code>&lt;p:toolBar&gt;</code> in a form since my open button is updating the <code>&lt;h:form id="frm"&gt;</code> and if <code>&lt;p:toolbar&gt;</code> is put in a form then <strong>update="frm"</strong> will give an exception that <code>&lt;h:form id="frm"&gt;</code> cant be referenced from the toolbar form<br> any help for my problem please</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload