2 Replies Latest reply on Feb 26, 2009 7:25 AM by Nick Belaevski

    rich:calendar could not get value

    zhao feng Newbie

      error list

      sourceId=UserForm:regdate[severity=(ERROR 2), summary=(UserForm:regdate: '2009-02-03' could not be understood as a date.), detail=(UserForm:regdate: '2009-02-03' could not be understood as a date. Example: 2009-02-26 )]


      <h:panelGroup>
       <rich:calendar id="regdate" datePattern="yyyy-MM-dd " value="#{userBeanAdd.userRegeDate}"/>
       </h:panelGroup>
      <h:panelGroup>
       <h:commandButton value="register" action="#{userBeanAdd.addUser}" styleClass="submitButton" />
       </h:panelGroup>
      


      in managed bean: userBeanAdd

       public Date getUserRegeDate() {
       return userRegeDate;
       }
      
       public void setUserRegeDate(Date userRegeDate) {
       this.userRegeDate = userRegeDate;
       }
      public String addUser(){
       String str="success";
       System.out.println(getUserRegeDate());
      return str;
      }