要在struts 中配置
<message-resources parameter="sb.ApplicationResources"/>
sb,是你的包名,把properties文件放在类包下面

解决方案 »

  1.   

    <message-resources parameter="strutsfirstdemo.app"/>
    我的文件是app.properties啊,没错的啊。。
    可是还是会出现上面的异常啊。。
      

  2.   

    你的Struts_comfige.xml是如何配的?是不是有问题?*-*
      

  3.   

    对肯定是cinfig有问题!其他处的错误!使初始化的时候不能加载.property文件!仔细检查啊!
      

  4.   

    应该是struts-config.xml的配置错误..看看你的大小写等有没有什么错误..
      

  5.   

    你配完properties文件后重启tomcat了吗?
      

  6.   

    再看看struts的配置说明,还需要下一个xml解析器。
    1.1版以前不用的。
      

  7.   

    to:chyihill(一手烟无罪) 
     ------------------------
     <message-resources parameter="strutsfirstdemo.app"/>
     我的文件是app.properties啊,没错的啊。。
     可是还是会出现上面的异常啊。。
     ------------------------
    根据你的描述,你应该包含如下文件
    /WEB-INF/classes/strutsfirstdemo/app.properties
    请检查路径
      

  8.   

    web.xml文件中<servlet>
        <servlet-name>action</servlet-name>
        <servlet-class>org.apache.struts.action.ActionServlet</servlet-class>
        <init-param>
          <param-name>debug</param-name>
          <param-value>2</param-value>
        </init-param>
        <init-param>
          <param-name>config</param-name>
          <param-value>/WEB-INF/struts-config.xml</param-value>
        </init-param>
        <init-param>
          <param-name>validate</param-name>
          <param-value>true</param-value>
        </init-param>
        <init-param>
          <param-name>application</param-name>
          <param-value>bao.ApplicationResources</param-value>
        </init-param>
        <load-on-startup>2</load-on-startup>
      </servlet>资源文件名:ApplicationResources.properties