[jboss-user] [JBoss Seam] - model validation failed:String index out of range: -1

umk do-not-reply at jboss.com
Sat May 26 09:19:48 EDT 2007


Hello, 

I'm trying to bind a Map entry to h:inputText. The code below successfully extracts the value for the key when the page is loaded, but when I submit it, the page reloads with an error alongside the field: model validation failed:String index out of range: -1 

>From the .xhtml

  | <h:form id="dataEntryForm">
  | ...
  | <h:inputText id="asdf" required="true" value="#{biomarkers['waist']}" />
  | ...
  | </h:form>
  | 

>From the session bean:

  | ...
  | @Out
  | Map<String, String> biomarkers = new HashMap<String, String>();
  | ...
  | // method code that preps the Map prior to being used
  | biomarkers.put("waist", "33.3");
  | ...
  | 

Thanks to anyone who can offer some assistance!


View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4048845#4048845

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4048845



More information about the jboss-user mailing list