This is a problem with the JSF spec, and currently there is nothing
that MyFaces can do about it.
If you look inside of UIInput's validate() method, you'll see why your
validator is not firing.
The validate method checks if the submittedValue is null. If so, it
does nothing.
According to the HTML spec, if you don't select anything in a listbox,
nothing gets put onto the request, which means that the submittedValue
will be null.
On 23 Feb 2005 16:16:15 -0000, mfaine <[EMAIL PROTECTED]> wrote:
> I have the following on my page:
>
> <h:selectOneListbox id="document" value="#{sessionData.selectedDocumentId}"
> required="true" size="5" style="width: 300px;" >
> <f:selectItems id="documentItem"
> value="#{sessionData.documentSelectItems}"/>
> </h:selectOneListbox>
>
> ... then
>
> <h:commandButton action="#{sessionData.editAction}"
> value="#{msg.common_edit}"
> actionListener="#{sessionData.currentDocumentListen}" />
>
> The editAction is allowed to execute even if selectedDocumentId is null?
> Actually it is the actionListener method that gets called regardless of the
> value for selectedDocumentId.
>
> Thanks,
> -Mark
>
>
--
-Heath Borders-Wing
[EMAIL PROTECTED]