velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Prabhakar Krishnaswami" <PKRIS...@dynix.com>
Subject Not able to retrieve errors
Date Tue, 15 Jun 2004 18:59:07 GMT
I am having a problem where I am not able to retrieve errors objects
saved in the request. I have saved the error objects as per the standard
protocol outlined in many struts textbooks:

 

              ActionError ae = new
ActionError("exception.required.field","Title");

             errArray.add(ActionErrors.GLOBAL_ERROR,ae);

             this.saveErrors(req,errArray);

             return map.findForward("copyfillinform");

 

I try to retrieve the error objects as below:

 

#if($errors.exist())

  #foreach ($e in $errors.all )

            <error>$e</error>

 

  #end

#end

 

when I print out the XML being generated, I don't see the error tag
along with the message being generated.  Is there a syntax error in
retrieving the error object?

 

Prabhakar Krishnaswami

Software Engineer

 

Dynix

pkrishnaswami@dynix.com

p 801-223-5817

f  801-223-5202

www.dynix.com
<file:///C:\Documents%20and%20Settings\PKrishna\Application%20Data\Micro
soft\Signatures\www.dynix.com> 

 


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message