This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes JSF and the fly likes illegalArgumentException Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » JSF
Bookmark "illegalArgumentException" Watch "illegalArgumentException" New topic


tun zaw

Joined: Jan 23, 2008
Posts: 22
Hi all!
i have some problem with jsf h:selectOneMenu.I received the illegalArgumentException.I read java server faces in action 2005 published
by manning.

"If the EnumManager can�t find an ArtifactType instance for the int
value, an IllegalArgumentException will be thrown."

I don,t understand the EnumManager.
Here is my code copied from JavaBeat.
please help me.


<h:form id="select">
<h:panelGrid columns="1">
<hutputText value="Select a Name : "/>
<h:selectOneMenu value="#{}">
<f:selectItem itemValue="SteveJobs" value="SteveJobs"/>
<f:selectItem itemValue="Sergey Brin" value="Sergey Brin"/>
<f:selectItem itemValue="Larry Page" value="Larry Page"/>
<f:selectItem itemValue="Dell" value="Dell"/>
<f:selectItem itemValue="Mark Anderson" value="Mark Anderson"/>
<h:commandButton value="Submit" action="#{selectOneBean.submit}"/>


public class SelectOneMenuBean {
private String name;

public String getName() {
return name;

public void setName(String name) { = name;
public String submit(){
return "selectOneMenu";




<hutputText value="Selected Name is : "/>
<hutputText value="#{}"/>
Krishna Srinivasan
Ranch Hand

Joined: Jul 28, 2003
Posts: 1844

Have you use the same code? it should work fine. Are you using MyFaces.

Krishna Srinivasan
Spring Tutorials, OCAJP Mock Questions, 400+ OCPJP Mock Questions
subject: illegalArgumentException
Similar Threads
Unable to call Action Methof
File upload
Navigation problem
faces-config not working
javax.xml.rpc.soap.SOAPFaultException: System.Web.Services.Protocols.SoapException: