On Sat, Jan 17, 2009 at 8:26 AM, Bjørn T Johansen <b...@havleik.no> wrote:

> I am trying to upgrade from an old Tomahawk version (1.1.7-snapshot) to
> 1.1.8 but when I do,I get a problem with the
> t:inputCalendar tag... I get the following exception..:
>
> Caused by: javax.faces.FacesException: Exception while calling encodeEnd on
> : {Component-Path : [Class:
> javax.faces.component.UIViewRoot,ViewId:
> /protected/order/general_t.jsp][Class:
> javax.faces.component.html.HtmlPanelGrid,Id: _idJsp0][Class:
> javax.faces.component.UIColumn,Id: _idJsp29][Class:
> javax.faces.component.html.HtmlForm,Id: formOrder][Class:
> org.apache.myfaces.custom.tabbedpane.HtmlPanelTabbedPane,Id:
> _idJsp30][Class: org.apache.myfaces.custom.tabbedpane.HtmlPanelTab,Id:
> _idJsp31][Class:
> javax.faces.component.UINamingContainer,Id: view_gen][Class:
> javax.faces.component.html.HtmlPanelGroup,Id:
> ordreChosenOrNew][Class: com.exadel.htmLib.components.UITable,Id:
> _idJsp32][Class:
> com.exadel.htmLib.components.UITr,Id: _idJsp88][Class:
> com.exadel.htmLib.components.UITd,Id: _idJsp89][Class:
> com.exadel.htmLib.components.UITable,Id: _idJsp90][Class:
> com.exadel.htmLib.components.UITr,Id: _idJsp91][Class:
> com.exadel.htmLib.components.UITd,Id: _idJsp94][Class:
> org.apache.myfaces.custom.calendar.HtmlInputCalendar,Id:
> avisdato]}
>
> at
> javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:778) at
> org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils.java:420)
> at
> org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChildren(RendererUtils.java:401)
> at
> org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils.java:418)
> at
> org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChildren(RendererUtils.java:401)
> at
> org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils.java:418)
> at
> org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChildren(RendererUtils.java:401)
> at
> org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils.java:418)
> at
> org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChildren(RendererUtils.java:401)
> at
> org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils.java:418)
> at
> org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChildren(RendererUtils.java:401)
> at
> org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils.java:418)
> at
> org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChildren(RendererUtils.java:401)
> at
> org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils.java:418)
> at
> org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChildren(RendererUtils.java:401)
> at
> org.apache.myfaces.shared_impl.renderkit.html.HtmlGroupRendererBase.encodeEnd(HtmlGroupRendererBase.java:78)
> at
> javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:775)
> ... 62 more
>
> Caused by:
> java.lang.IllegalArgumentException at java.sql.Date.getHours(Date.java:143)
> at
> org.apache.myfaces.dateformat.SimpleDateFormatter.formatOps(SimpleDateFormatter.java:839)
> at
> org.apache.myfaces.dateformat.SimpleDateFormatter.format(SimpleDateFormatter.java:1207)
> at
>
> org.apache.myfaces.custom.calendar.HtmlCalendarRenderer$CalendarDateTimeConverter.getAsString(HtmlCalendarRenderer.java:1204)
> at
> org.apache.myfaces.custom.calendar.HtmlCalendarRenderer.renderPopup(HtmlCalendarRenderer.java:198)
> at
> org.apache.myfaces.custom.calendar.HtmlCalendarRenderer.encodeEnd(HtmlCalendarRenderer.java:149)
> at
> javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:775)
> ... 78 more
>
>
> Some problem when getting the date or?
>
> This is my jsp code..:
>
> <t:inputCalendar id="avisdato" monthYearRowClass="yearMonthHeader"
> weekRowClass="weekHeader"
>                            currentDayCellClass="currentDayCell"
> value="#{orderBean.ordre.avisdato}" renderAsPopup="true"
>                            popupDateFormat="dd.MM.yyyy" styleClass="input"
> renderPopupButtonAsImage="true"/>
>
> where avisdato is of type java.util.Date
>
>
> Any idea why this happends?
>

Hi

t:inputCalendar uses SimpleDateFormatter to handle dates, but requires a
real instance of java.util.Date. Use java.sql.Date instances (override some
methods required by SimpleDateFormatter) cause problems.

regards

Leonardo  Uribe

>
> Regards,
>
> BTJ
>
> --
>
> -----------------------------------------------------------------------------------------------
> Bjørn T Johansen
>
> b...@havleik.no
>
> -----------------------------------------------------------------------------------------------
> Someone wrote:
> "I understand that if you play a Windows CD backwards you hear strange
> Satanic messages"
> To which someone replied:
> "It's even worse than that; play it forwards and it installs Windows"
>
> -----------------------------------------------------------------------------------------------
>

Reply via email to