在javabean中用Integer代替int就可以了

解决方案 »

  1.   

    确定你的类com.onizuka.bean.test中setget方法的变量类型是一致的?int id;public void setId(int id) {
    this.id = id;
    }public int getId() {
    return this.id;
    }都是int吗?页面的标签没有问题。
      

  2.   

    添加format属性或formatKey属性,如<bean:write name="a" property="age" format="00,000"/>
    <bean:write name="a" property="id" format="00,000"/>
      

  3.   

    看看你的propertise文件在struts-config.xml文件里面有没有设置!
    错误提示说找不到你propertise文件!