Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

What is the use of ActionErrors in Struts

Answer Posted / biru

In Validate method for each validation error we need to
construct an object of ActionMessage class and we need to
add each ActionMessage class object to ActionErrors class
object .
Ex:
public ActionErrors validate(ActionMapping
am,HttpServletRequest)
{
ActionErrors aes=new ActionErrors();
if(uname.length==0)
{ ActionMessage am1=new ActionMessage("uname.wrong")
aes.add("uname",am1);
}
}

Is This Answer Correct ?    5 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the purpose of form-beans tag in struct-config.xml?

902


Which design pattern the interceptors in struts2 is based on?

911


State an example of struts configuration file as an action parameter for action servlet.

998


Why was reload removed from struts (since 1.1)?

974


What is struts 2 framework in java?

1035


What is the need of struts?

972


What is the purpose of @expressionvalidator annotation?

1042


What are the reasons for an error message not being displayed while developing struts application?

939


How struts 2 validation works?

1065


Can I have html form property without associated getter and setter formbean methods?

1004


How you will enable front-end validation based on the xml in validation.xml?

1066


What is an interceptor stack?

1031


What are the core classes of struts?

1030


What are action classes in struts?

957


What is the difference between empty default namespace and root namespace?

1123