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...

Can multiple catch statements be used in exceptions ?

Answer Posted / sakthi k

Yes we can use multiple catch statement for the exception.
try
{
Sop("exception");
}
catch(NumberFormatException)
{
}
catch(Exception)
{
}
we have to include the child exception above the parent
exception otherwise it shows an error. .

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Name few "optional" classes introduced with java 8 ?

1108


Why to use nested classes in java?

1096


What is primitive array?

881


What state does a thread enter when it terminates its processing in java programming?

1020


Can a class be private or protected in java?

1047


Why java is used everywhere?

984


What is the purpose of the runtime class in java programming?

1043


Define how objects are stored in java?

1040


How does a cookie work in Servlets?

829


What isan abstract class and when do you use it?

1573


What class allows you to read objects directly from a stream?

1307


Can a class extend more than one class?

1097


Can an object subclass another object?

1064


Is arraylist an object in java?

1116


What is nested interface?

993