You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by "Ajit.T" <cy...@gmail.com> on 2006/06/19 18:46:38 UTC
Error while Using s:inputTextAjax
Hi,
This is the error stacktrace(partial) i get when I try using the
s:inputTextAjax component in my form as given in examples
viz.'inputAjax.jsp'. Can anyone help me decipher this.? I am using 1.1.4
snapshots of myfaces(api,impl),tomahawk,tomahawk-sandbox.
Kindly let me know what am i missing..
thanks ,
Ajit
ApplicationDispatcher[/project-1] Servlet.service() for servlet jsp threw
exception
java.lang.ClassCastException
at
org.apache.myfaces.custom.ajax.util.AjaxRendererUtils.writeAjaxScript(AjaxRendererUtils.java:128)
at
org.apache.myfaces.custom.ajax.util.AjaxRendererUtils.writeAjaxScript(AjaxRendererUtils.java:86)
at
org.apache.myfaces.custom.inputAjax.HtmlInputTextAjaxRenderer.encodeJavascript(HtmlInputTextAjaxRenderer.java:64)
at
org.apache.myfaces.custom.inputAjax.HtmlInputTextAjaxRenderer.encodeEnd(HtmlInputTextAjaxRenderer.java:95)
at
javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:536)
at
org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils.java:442)
at
org.apache.myfaces.shared_impl.renderkit.html.HtmlGridRendererBase.renderChildren(HtmlGridRendererBase.java:216)
at
org.apache.myfaces.shared_impl.renderkit.html.HtmlGridRendererBase.encodeEnd(HtmlGridRendererBase.java:98)
at
javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:536)
at
org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils.java:442)
at
org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChildren(RendererUtils.java:419)
at
org.apache.myfaces.shared_impl.renderkit.html.HtmlGroupRendererBase.encodeEnd(HtmlGroupRendererBase.java:75)
--
View this message in context: http://www.nabble.com/Error-while-Using-s%3AinputTextAjax-t1812568.html#a4940265
Sent from the MyFaces - Users forum at Nabble.com.
Have this too: Error while Using s:inputTextAjax
Posted by KevinS <ke...@freenet-ag.de>.
:-(
I am also experiencing the same ClassCastException:
java.lang.ClassCastException: javax.faces.component.html.HtmlMessages
at
org.apache.myfaces.custom.ajax.util.AjaxRendererUtils.writeAjaxScript(AjaxRendererUtils.java:128)
For the last two days I have been trying to get some 1.1.5 Sandbox examples
to work and am at the end of my rope.
Does anyone know if a fix is necessary or if this jsf-code is incorrect:
-- TOP OF JSP FILE --
<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
<%@ taglib uri="http://myfaces.apache.org/tomahawk" prefix="t"%>
<%@ taglib uri="http://myfaces.apache.org/sandbox" prefix="s"%>
<f:loadBundle basename="Messages" var="messages"/>
-- IN BODY TAG INSIDE VIEW TAG--
<t:messages globalOnly="true" style="color: red;" styleClass="errorMessage"
/>
<h:form>
<h:panelGrid>
<h:outputText styleClass="standard_bold" value="Input The Ajax-Aware
Zipcode"/>
<h:panelGrid columns="2">
<s:inputTextAjax
id="zipcode"
value="#{addressListBean.activeAddress.zipCode}"
validator="#{customerValidator.validateAreaCode}"
errorStyle="border:1px solid red; color:red;"/>
<t:message styleClass="errorMessage" for="zipcode"/>*/%>
</h:panelGrid>
<f:verbatim>This component demonstrates ajax updating ability when you
change the
text. <br/> An error message is displayed if the given area code is
invalid.</f:verbatim>
</h:panelGrid>
</h:form>
Best Regards,
Kevin
Gerald M?llan wrote:
>
>> I am using t:message for the inputtext component, though the form level
>> global messages component are h:message.
>
> Hm..you mean h:messages?
>
> Try t:messages. Maybe thats the problem.
>
> cheers,
>
> Gerald
>
>
--
View this message in context: http://www.nabble.com/Error-while-Using-s%3AinputTextAjax-tf1812568.html#a5103528
Sent from the MyFaces - Users forum at Nabble.com.
Re: Error while Using s:inputTextAjax
Posted by Gerald Müllan <bi...@gmail.com>.
> I am using t:message for the inputtext component, though the form level
> global messages component are h:message.
Hm..you mean h:messages?
Try t:messages. Maybe thats the problem.
cheers,
Gerald
On 6/20/06, Ajit.T <cy...@gmail.com> wrote:
>
> I am using t:message for the inputtext component, though the form level
> global messages component are h:message.
> --
> View this message in context: http://www.nabble.com/Error-while-Using-s%3AinputTextAjax-t1812568.html#a4956755
> Sent from the MyFaces - Users forum at Nabble.com.
>
>
--
Gerald Müllan
Schelleingasse 2/11
1040 Vienna, Austria
0043 699 11772506
gerald.muellan@gmail.com
Re: Error while Using s:inputTextAjax
Posted by "Ajit.T" <cy...@gmail.com>.
I am using t:message for the inputtext component, though the form level
global messages component are h:message.
--
View this message in context: http://www.nabble.com/Error-while-Using-s%3AinputTextAjax-t1812568.html#a4956755
Sent from the MyFaces - Users forum at Nabble.com.
Re: Error while Using s:inputTextAjax
Posted by Gerald Müllan <bi...@gmail.com>.
Hi,
which Messages and/or Message component do you use?
cheers,
Gerald
On 6/19/06, Ajit.T <cy...@gmail.com> wrote:
>
> Hi,
> This is the error stacktrace(partial) i get when I try using the
> s:inputTextAjax component in my form as given in examples
> viz.'inputAjax.jsp'. Can anyone help me decipher this.? I am using 1.1.4
> snapshots of myfaces(api,impl),tomahawk,tomahawk-sandbox.
> Kindly let me know what am i missing..
> thanks ,
> Ajit
>
> ApplicationDispatcher[/project-1] Servlet.service() for servlet jsp threw
> exception
> java.lang.ClassCastException
> at
> org.apache.myfaces.custom.ajax.util.AjaxRendererUtils.writeAjaxScript(AjaxRendererUtils.java:128)
> at
> org.apache.myfaces.custom.ajax.util.AjaxRendererUtils.writeAjaxScript(AjaxRendererUtils.java:86)
> at
> org.apache.myfaces.custom.inputAjax.HtmlInputTextAjaxRenderer.encodeJavascript(HtmlInputTextAjaxRenderer.java:64)
> at
> org.apache.myfaces.custom.inputAjax.HtmlInputTextAjaxRenderer.encodeEnd(HtmlInputTextAjaxRenderer.java:95)
> at
> javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:536)
> at
> org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils.java:442)
> at
> org.apache.myfaces.shared_impl.renderkit.html.HtmlGridRendererBase.renderChildren(HtmlGridRendererBase.java:216)
> at
> org.apache.myfaces.shared_impl.renderkit.html.HtmlGridRendererBase.encodeEnd(HtmlGridRendererBase.java:98)
> at
> javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:536)
> at
> org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChild(RendererUtils.java:442)
> at
> org.apache.myfaces.shared_impl.renderkit.RendererUtils.renderChildren(RendererUtils.java:419)
> at
> org.apache.myfaces.shared_impl.renderkit.html.HtmlGroupRendererBase.encodeEnd(HtmlGroupRendererBase.java:75)
> --
> View this message in context: http://www.nabble.com/Error-while-Using-s%3AinputTextAjax-t1812568.html#a4940265
> Sent from the MyFaces - Users forum at Nabble.com.
>
>
--
Gerald Müllan
Schelleingasse 2/11
1040 Vienna, Austria
0043 699 11772506
gerald.muellan@gmail.com