ITPub博客

首页 > 应用开发 > IT综合 > org.springframework.beans.NotWritablePropertyException: Invalid property

org.springframework.beans.NotWritablePropertyException: Invalid property

原创 IT综合 作者:haijie1984 时间:2009-04-29 16:41:06 0 删除 编辑

问题:

Exception in thread "main" org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'programmaticManager' defined in URL [file:src/applicationContext.xml]: Error setting property values; nested exception is org.springframework.beans.NotWritablePropertyException: Invalid property 'iTestDao' of bean class [test.ProgrammaticManager]: Bean property 'iTestDao' is not writable or has an invalid setter method. Did you mean 'ITestDao'?

解决方法:

DAO变量名有问题,可能是定义的DAO变量名不符合Struts的什么规范吧。将ITestDao类型变量iTestDao,改成其他名字,就OK了。

[@more@]

来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/7282477/viewspace-1021483/ ,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论

注册时间:2009-06-23

  • 博文量
    37
  • 访问量
    415686