error on bean:message and resource properties file ?

Hi everyone! I'm new to struts and i just can't figure out why tomcat's giving me an error. I've manage to run a simple example but when i use the bean:message tag i get this error

ERROR IS:

java.lang.NullPointerException

org.apache.struts.taglib.TagUtils.retrieveMessageResources(TagUtils.java:1175)

org.apache.struts.taglib.TagUtils.message(TagUtils.java:1038)

org.apache.struts.taglib.bean.MessageTag.doStartTag(MessageTag.java:224)

org.apache.jsp.index_jsp._jspx_meth_bean_message_0(org.apache.jsp.index_jsp:135)

org.apache.jsp.index_jsp._jspx_meth_html_html_0(org.apache.jsp.index_jsp:101)

org.apache.jsp.index_jsp._jspService(org.apache.jsp.index_jsp:69)

org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)

javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:322)

org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:291)

org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241)

javax.servlet.http.HttpServlet.service(HttpServlet.java:802)

Can anyone help me with this problem?

my ApplicationResources.propeties file is in WEB-INF/classes

index.jsp

<%@ page language="java" %>

<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean" %>

<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html" %>

<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic" %>

<html:html locale="true">

<head>

<title> <bean:message key="index.title"/> </title>

</head>

<body>

<html:link module="/exercise" action="/welcome">Taglib Test Pages</html:link>

</body>

</html:html>

web.xml

<?xml version="1.0" encoding="iso-8859-1"?>

<!DOCTYPE web-app

PUBLIC"-//Sun Microsystems, Inc.//DTD Web Application 2.2//EN"

"http://java.sun.com/j2ee/dtds/web-app_2_2.dtd">

<web-app>

<!-- Action Servlet Configuration -->

<servlet>

<servlet-name>action</servlet-name>

<servlet-class>org.apache.struts.action.ActionServlet</servlet-class>

<!-- Resources bundle baseclass -->

<init-param>

<param-name>application</param-name>

<param-value>ApplicationResources</param-value>

</init-param>

<!-- Context-relative path to the XML resource containing Struts configuration information -->

<init-param>

<param-name>config</param-name>

<param-value>/WEB-INF/struts-config.xml</param-value>

</init-param>

<!-- The debugging detail levelforthis servlet, which controls how much information is logged. -->

<init-param>

<param-name>debug</param-name>

<param-value>2</param-value>

</init-param>

<init-param>

<param-name>detail</param-name>

<param-value>2</param-value>

</init-param>

<load-on-startup>1</load-on-startup>

</servlet>

<!-- Action Servlet Mapping -->

<servlet-mapping>

<servlet-name>action</servlet-name>

<url-pattern>*.do</url-pattern>

</servlet-mapping>

<!-- The Welcome File List -->

<welcome-file-list>

<welcome-file>index.jsp</welcome-file>

</welcome-file-list>

<!-- Struts Tag Library Descriptors -->

<taglib>

<taglib-uri>/WEB-INF/struts-bean.tld</taglib-uri>

<taglib-location>/WEB-INF/struts-bean.tld</taglib-location>

</taglib>

<taglib>

<taglib-uri>/WEB-INF/struts-html.tld</taglib-uri>

<taglib-location>/WEB-INF/struts-html.tld</taglib-location>

</taglib>

<taglib>

<taglib-uri>/WEB-INF/struts-logic.tld</taglib-uri>

<taglib-location>/WEB-INF/struts-logic.tld</taglib-location>

</taglib>

<!-- Application Tag Library Descriptor -->

<taglib>

<taglib-uri>/WEB-INF/app.tld</taglib-uri>

<taglib-location>/WEB-INF/app.tld</taglib-location>

</taglib>

</web-app>

Please help..thanks in advance

[5104 byte] By [Mona_tajika] at [2007-10-2 18:41:16]
# 1
BTW my properties fileWEB-INF/classes/ApplicationResources.propertiesindex.title = Welcome!please please help!!! thanks
Mona_tajika at 2007-7-13 20:03:26 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 2
Have u specified the tag<message-resources parameter="ApplicationResources" />in ur struts-config.xml.just check this.
doubtsmana at 2007-7-13 20:03:26 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 3

I have that on my struts-config.xml

<?xml version="1.0" encoding="ISO-8859-1"?>

<!DOCTYPE struts-config PUBLIC

"-//Apache Software Foundation//DTD Struts Configuration 1.0//EN"

"http://jakarta.apache.org/struts/dtds/struts-config_1_0.dtd">

<struts-config>

<form-beans>

</form-beans>

<global-forwards>

</global-forwards>

<action-mappings>

</action-mappings>

<message-resources parameter="ApplicationResources"/>

</struts-config>

and I also include it on my web.xml file

<!-- Resources bundle base class -->

<init-param>

<param-name>application</param-name>

<param-value>ApplicationResources</param-value>

</init-param>

Mona_tajika at 2007-7-13 20:03:26 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 4
why u have kept ur resources file in WEB_INF/classes directory.?just prefix the index.jsp with " / ".like below.<welcome-file-list><welcome-file>/index.jsp</welcome-file></welcome-file-list>
doubtsmana at 2007-7-13 20:03:26 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 5
Did that but still doesnt work :( any other ideas?
Mona_tajika at 2007-7-13 20:03:26 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...
# 6
Hi,even i faced the same problem and i had put the property file in a package. like for eg./WEB-INF/classes/prop/ApplicationResources.propTry it!
AnithaPRa at 2007-7-13 20:03:26 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...