File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JSF and the fly likes Problem with selectOneMenu in MyFaces 1.1.1 Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


JavaRanch » Java Forums » Java » JSF
Reply Bookmark "Problem with selectOneMenu in MyFaces 1.1.1" Watch "Problem with selectOneMenu in MyFaces 1.1.1" New topic
Author

Problem with selectOneMenu in MyFaces 1.1.1

Scott Brissenden
Greenhorn

Joined: Dec 12, 2005
Posts: 1
I'm trying to upgrade my app to use MyFaces 1.1.1.

A selectOneMenu that I have been using successfully in MyFaces 1.0.9 is now broken. Whenever I try to submit my form I get the error "Value is not a valid option"

The code looks legal to me and is as follows:

<h:selectOneMenu id="prioritySrc" value="#{taskList.priority}">
<f:selectItems value="#{taskForm.priorityItems}"/>
</h:selectOneMenu>

The backing bean code is:

private static SelectItem[] priorityItems = {
new SelectItem(new Integer(1), "High"),
new SelectItem(new Integer(2), "Medium"),
new SelectItem(new Integer(3), "Low"),
};

public SelectItem[] getPriorityItems() {
return priorityItems;
}

Does anyone know what the error message means or if I am doing something obviously wrong?
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Problem with selectOneMenu in MyFaces 1.1.1
 
Similar Threads
Problem With selectOneMenu
Selecting an item using selectOneMenu
Error 500: "{2}" Conversion Error setting value ''{0}'' for ''{1}''.
Populated UISelect components via Database
Validation Error on SelectOneMenu