当前位置: 代码迷 >> Java Web开发 >> javax.faces.el.EvaluationException: Expression Error: Named
  详细解决方案

javax.faces.el.EvaluationException: Expression Error: Named

热度:689   发布时间:2016-04-17 01:10:43.0
期待大神出现(Expression Error: Named Object: 'userService' not found.)
我得工程配置是JSF+Hibeinate+Spring三个结合起来的,出现这个错误,救我!
错误:
严重: Servlet.service() for servlet jsp threw exception
javax.faces.el.EvaluationException: Expression Error: Named Object: 'userService' not found.
at com.sun.faces.config.ManagedBeanFactory.getScopeForSingleExpression(ManagedBeanFactory.java:998)
at com.sun.faces.config.ManagedBeanFactory.hasValidLifespan(ManagedBeanFactory.java:931)
at com.sun.faces.config.ManagedBeanFactory.evaluateValueBindingGet(ManagedBeanFactory.java:892)
at com.sun.faces.config.ManagedBeanFactory.setPropertiesIntoBean(ManagedBeanFactory.java:553)
at com.sun.faces.config.ManagedBeanFactory.newInstance(ManagedBeanFactory.java:234)


------解决方案--------------------
spring 配置有问题!
------解决方案--------------------
因为没有配置过JSF,所以不知道faces-config.xml应该如何配置。但是目前现象应该是faces-config.xml中没有找到在applicationContext.xml配置的userService。建议找下Spring和JSF配合的资料查看下
  相关解决方案