Caused by: javax.el.PropertyNotFoundException: Property [userName] not found on type [java.lang.String]

Caused by: javax.el.PropertyNotFoundException: Property [userName] not found on type [java.lang.String]
at javax.el.BeanELResolver$BeanProperties.get(BeanELResolver.java:260)
at javax.el.BeanELResolver$BeanProperties.access$300(BeanELResolver.java:212)
at javax.el.BeanELResolver.property(BeanELResolver.java:347)
at javax.el.BeanELResolver.getValue(BeanELResolver.java:92)
at org.apache.jasper.el.JasperELResolver.getValue(JasperELResolver.java:110)
at org.apache.el.parser.AstValue.getValue(AstValue.java:169)
at org.apache.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:190)
at org.apache.jasper.runtime.PageContextImpl.proprietaryEvaluate(PageContextImpl.java:944)
at org.apache.jsp.main_jsp._jspService(main_jsp.java:120)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:476)
... 61 more

意思就是沒有找到el表达式中的属性,检查一下是不是属性名写错了

原文地址:https://www.cnblogs.com/jjking/p/11660571.html

时间: 2024-10-13 12:06:49

Caused by: javax.el.PropertyNotFoundException: Property [userName] not found on type [java.lang.String]的相关文章

Caused by: javax.el.PropertyNotFoundException: Property 'product' not found on type java.lang.String

今天在JSP利用EL表达式取值报了 "javax.el.PropertyNotFoundException”,经过debug和打印将问题定位到这段代码: HTML应该是没啥问题,看提示在java.lang.string类型上找不到属性“product”,应该是EL表达式哪里写错了,然后将图中EL表达式重新写了一遍: 然后神奇的不报错了,搞得我一脸蒙蔽,我将每段代码都比对了一下,没发现哪里不对,干就干彻底,替换每段代码测试,结果第一段替换进去就OK了 仔细检查了两段代码: //报错代码 <c

javax.el.PropertyNotFoundException: Property &#39;name&#39; not found on type java.lang.String

javax.el.PropertyNotFoundException: Property 'name' not found on type java.lang.String javax.el.BeanELResolver$BeanProperties.get(BeanELResolver.java:193) javax.el.BeanELResolver.property(BeanELResolver.java:267) javax.el.BeanELResolver.getValue(Bean

javax.el.PropertyNotFoundException: Property &#39;id&#39; not found on type java.lang.Integer

javax.el.PropertyNotFoundException: Property 'id' not found on type java.lang.Integer    at javax.el.BeanELResolver$BeanProperties.get(BeanELResolver.java:237)    at javax.el.BeanELResolver$BeanProperties.access$400(BeanELResolver.java:214)    at jav

[java] javax.el.PropertyNotFoundException: Property &#39;id&#39; not found on type bean.Student

问题提出: 在使用MyEclipse开发Java Web时,调用DAO和Java Bean出现了如下错误: 严重: Servlet.service() for servlet [jsp] in context with path [/JDBCbyDao] threw exception [An exception occurred processing JSP page /student.jsp at line 37 34: 35: <c:forEach items="${ student

Property &#39;id&#39; not found on type java.lang.String问题解决

一般出现上述问题:存在两种情况 1.你的程序的属性没有提供getter方法 2.在<c:forEach var="list" items="${requestScope.list}" varStatus="vs">这里你没有采取EL表达式 但是我却犯了一个很弱智的错误 在这里items="${requestScope.list}"我写成了 items=" ${requestScope.list}"

Property &#39;XXX&#39; not found on type java.lang.String解决方案

一,标签指令错误. 原指令标签: [java] view plain copy <%@ taglib prefix="c" uri="http://j ava.sun.com/jstl/core" %> 改正后的指令标签: [java] view plain copy <%@ taglib prefix="c" uri="http://j ava.sun.com/jsp/jstl/core" %> 二,

Property &#39;id&#39; not found on type java.lang.String

改为 忘写了$符,取不出来,因此报错! Property 'id' not found on type java.lang.String

javax.el.PropertyNotFoundException: Property &#39;Email&#39; not found&#183;&#183;&#183;

1.有空格 javax.el.PropertyNotFoundException: Property 'name' not found on type java.lang.String 在jstl标签属性中的""中间不能有空格,真实死都不知道怎么死的. 原: <c:forEach items="${userlist} " var="user"> 把"${userlist} "中间的空格去掉,改为: <c:fo

spring mvc出现 Failed to convert property value of type &#39;java.lang.String&#39; to required type &#39;java.util.Date&#39; for property &#39;endtime&#39;

在使用spring mvc中,绑定页面传递时间字符串数据给Date类型是出错: Failed to convert property value of type [java.lang.String] to required type [java.util.Date] for property 'expert.birthdate'; nested exception is java.lang.IllegalArgumentException: Cannot convert value of typ