jsp - java.lang.IllegalStateException: Component javax.faces.component.UIViewRoot@19ded20 not expected type -
i'm retrieving exception when open jsf page. how caused , how can fix it?
org.apache.jasper.jasperexception: exception occurred processing jsp page /searchresultjsf.jsp @ line 18 15: <body> 16: <h1>search result</h1> 17: 18: <h:datatable id ="abc" value="#{searchbean.dealerlist}" var="dealer"> 19: <h:column> 20: <f:facet name="header" > 21: <h:outputtext value="dealer name "/> stacktrace: org.apache.jasper.servlet.jspservletwrapper.handlejspexception(jspservletwrapper.java:505) org.apache.jasper.servlet.jspservletwrapper.service(jspservletwrapper.java:398) org.apache.jasper.servlet.jspservlet.servicejspfile(jspservlet.java:342) org.apache.jasper.servlet.jspservlet.service(jspservlet.java:267) javax.servlet.http.httpservlet.service(httpservlet.java:717) org.netbeans.modules.web.monitor.server.monitorfilter.dofilter(monitorfilter.java:390) com.sun.faces.context.externalcontextimpl.dispatch(externalcontextimpl.java:408) com.sun.faces.application.viewhandlerimpl.executepagetobuildview(viewhandlerimpl.java:442) com.sun.faces.application.viewhandlerimpl.renderview(viewhandlerimpl.java:115) com.sun.faces.lifecycle.renderresponsephase.execute(renderresponsephase.java:106) com.sun.faces.lifecycle.lifecycleimpl.phase(lifecycleimpl.java:251) com.sun.faces.lifecycle.lifecycleimpl.render(lifecycleimpl.java:144) javax.faces.webapp.facesservlet.service(facesservlet.java:245) org.netbeans.modules.web.monitor.server.monitorfilter.dofilter(monitorfilter.java:390) root cause javax.servlet.servletexception: javax.servlet.jsp.jspexception: java.lang.illegalstateexception: component javax.faces.component.uiviewroot@19ded20 not expected type. expected: javax.faces.component.uidata. perhaps you're missing tag? org.apache.jasper.runtime.pagecontextimpl.dohandlepageexception(pagecontextimpl.java:858) org.apache.jasper.runtime.pagecontextimpl.handlepageexception(pagecontextimpl.java:791) org.apache.jsp.searchresultjsf_jsp._jspservice(searchresultjsf_jsp.java:94) org.apache.jasper.runtime.httpjspbase.service(httpjspbase.java:70) javax.servlet.http.httpservlet.service(httpservlet.java:717) org.apache.jasper.servlet.jspservletwrapper.service(jspservletwrapper.java:374) org.apache.jasper.servlet.jspservlet.servicejspfile(jspservlet.java:342) org.apache.jasper.servlet.jspservlet.service(jspservlet.java:267) javax.servlet.http.httpservlet.service(httpservlet.java:717) org.netbeans.modules.web.monitor.server.monitorfilter.dofilter(monitorfilter.java:390) com.sun.faces.context.externalcontextimpl.dispatch(externalcontextimpl.java:408) com.sun.faces.application.viewhandlerimpl.executepagetobuildview(viewhandlerimpl.java:442) com.sun.faces.application.viewhandlerimpl.renderview(viewhandlerimpl.java:115) com.sun.faces.lifecycle.renderresponsephase.execute(renderresponsephase.java:106) com.sun.faces.lifecycle.lifecycleimpl.phase(lifecycleimpl.java:251) com.sun.faces.lifecycle.lifecycleimpl.render(lifecycleimpl.java:144) javax.faces.webapp.facesservlet.service(facesservlet.java:245) org.netbeans.modules.web.monitor.server.monitorfilter.dofilter(monitorfilter.java:390) root cause java.lang.illegalstateexception: component javax.faces.component.uiviewroot@19ded20 not expected type. expected: javax.faces.component.uidata. perhaps you're missing tag? com.sun.faces.taglib.html_basic.datatabletag.setproperties(datatabletag.java:265) javax.faces.webapp.uicomponentclassictagbase.findcomponent(uicomponentclassictagbase.java:604) javax.faces.webapp.uicomponentclassictagbase.dostarttag(uicomponentclassictagbase.java:1126) com.sun.faces.taglib.html_basic.datatabletag.dostarttag(datatabletag.java:372) org.apache.jsp.searchresultjsf_jsp._jspx_meth_h_005fdatatable_005f0(searchresultjsf_jsp.java:117) org.apache.jsp.searchresultjsf_jsp._jspservice(searchresultjsf_jsp.java:84) org.apache.jasper.runtime.httpjspbase.service(httpjspbase.java:70) javax.servlet.http.httpservlet.service(httpservlet.java:717) org.apache.jasper.servlet.jspservletwrapper.service(jspservletwrapper.java:374) org.apache.jasper.servlet.jspservlet.servicejspfile(jspservlet.java:342) org.apache.jasper.servlet.jspservlet.service(jspservlet.java:267) javax.servlet.http.httpservlet.service(httpservlet.java:717) org.netbeans.modules.web.monitor.server.monitorfilter.dofilter(monitorfilter.java:390) com.sun.faces.context.externalcontextimpl.dispatch(externalcontextimpl.java:408) com.sun.faces.application.viewhandlerimpl.executepagetobuildview(viewhandlerimpl.java:442) com.sun.faces.application.viewhandlerimpl.renderview(viewhandlerimpl.java:115) com.sun.faces.lifecycle.renderresponsephase.execute(renderresponsephase.java:106) com.sun.faces.lifecycle.lifecycleimpl.phase(lifecycleimpl.java:251) com.sun.faces.lifecycle.lifecycleimpl.render(lifecycleimpl.java:144) javax.faces.webapp.facesservlet.service(facesservlet.java:245) org.netbeans.modules.web.monitor.server.monitorfilter.dofilter(monitorfilter.java:390)
this important bit:
javax.servlet.servletexception: javax.servlet.jsp.jspexception: java.lang.illegalstateexception: component javax.faces.component.uiviewroot@19ded20 not expected type. expected: javax.faces.component.uidata. perhaps you're missing tag?
you forgot wrap page jsf tags within <f:view>
. page has this:
<%@taglib uri="http://java.sun.com/jsf/core" prefix="f" %> <%@taglib uri="http://java.sun.com/jsf/html" prefix="h" %> <!doctype html> <f:view> <html lang="en"> <head> <title>insert title here</title> </head> <body> insert content here </body> </html> </f:view>
Comments
Post a Comment