---- Julien Martin <[EMAIL PROTECTED]> schrieb:
> Hello,
> 
> Suppose I have two h:forms each with one h:command button, all of which are
> on a jsf page. I would like to find a way to display error messages with two
> h:message components each working for a given h:command button but it seems
> that the for attribute of a h:message can't point to a h:command button.
> What is the best way of achieving the desired behavior?
> Julien.
> 
> 
> <h:form id="companies-netting-process-form">
> <h:message showDetail="true" showSummary="true"
> for="companies-netting-process-form"/>
> <h:commandButton id="companies-netting-process-button" action="#{
> NettingManagedBean.copyCompanies}" value="Traitement netting companies" />
> </h:form>
> 
> <f:verbatim>
> <br/><br/><br/><br/><br/><br/><br/><br/><br/><br/>
> </f:verbatim>
> 
> <h:form id="amounts-netting-process-form">
> <h:message showDetail="true" showSummary="true"
> for="amounts-netting-process-form"/>
> <h:commandButton id="amounts-netting-process-button" action="#{
> NettingManagedBean.copyAmounts}" value="Traitement netting amounts" />
> </h:form>

The "for" attribute of the h:message component means that it renders output 
only if an error message is explicitly attached to the component that its 
for-attribute references.

What component are your action messages attaching the error messages to?

Regards,

Simon

Reply via email to