jsp 运行时报错Cannot find a method to write property [firstName] of type [java.lang.String] in a bean of type [main.Employee]

原因: 代码没有安装bean的格式写 setFirstName写成了setFristName

错误代码

public void setFristName(String firstName) {
        this.firstName = firstName;
    }

修改代码后通过

public void setFirstName(String firstName) {
        this.firstName = firstName;
    }

 

posted @ 2019-04-09 21:32  江期玉  阅读(1033)  评论(0编辑  收藏  举报