Hi, The solution is perfect. I forgot initialization. Now I dont get any error but nothing is displayed when the error is actually to be thrown. I get blank page and it doesn't go the actual page and show the error. Here is my struts-config.xml
<action path="/upload-submit" type="upload.UploadAction" name="uploadForm" scope="request" validate="true" input="/upload/upload.jsp"> <forward name="failure" path="/upload/upload.jsp" /> <forward name="display" path="/upload/display.jsp" /> </action> Any ideas? Uma -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Thursday, December 23, 2004 6:43 PM To: Struts Users Mailing List Subject: Re: NullPointerException IF the exception is actually being thrown here, then I'm guessing that you haven't instantiated a instance of ActionErrors e.g. ActionErrors errors = new ActionErrors(); Dennis "uma.k" <[EMAIL PROTECTED]> 12/23/2004 07:40 AM Please respond to "Struts Users Mailing List" <user@struts.apache.org> To "'Struts Users Mailing List'" <user@struts.apache.org> cc Subject NullPointerException I get NullPointerException in validate() at this line errors.add(ActionMessages.GLOBAL_MESSAGE, new ActionMessage("error.text.required")); This is my ApplicationResources.properties file with this line error.text.required=Text is required What could be the reason for NullPointerException? Uma --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]