1 Reply Latest reply on May 11, 2010 5:08 AM by Ilya Shaikovsky

    Cannot make rich:paint2D example work

    ZJ DA Newbie

      Hi, I copied painter.xhtml, PaintBean.java and PaintData.java from richfaces demo, and add 2 back beans in faces-config.xml.  However, I got the following error:

      SEVERE: Error Rendering View[/paint.jsp]
      java.lang.IllegalArgumentException: Illegal color value: [0] for component j_id3:j_id11
          at org.richfaces.renderkit.ColorPickerRendererBase.validateColorString(ColorPickerRendererBase.java:69)
          at org.richfaces.renderkit.html.ColorPickerRenderer.doEncodeEnd(ColorPickerRenderer.java:470)
          at org.richfaces.renderkit.html.ColorPickerRenderer.doEncodeEnd(ColorPickerRenderer.java:495)
          at org.ajax4jsf.renderkit.RendererBase.encodeEnd(RendererBase.java:134)



      The color is the type of int and getColor() of PaintData.jave returns 0 initially.  What else do I miss?  Where should I initialize the color, text and scale?