File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Threads and Synchronization and the fly likes try catch and finally blocks Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Threads and Synchronization
Reply locked New topic

try catch and finally blocks

narasimha munagala

Joined: Aug 12, 2007
Posts: 7
Hi to everyone
I am new to java i want to know
in all the try ,catch,finally blocks return statements exists
if an exception raised in the try block then which return
statement execute
and if an exception not raised in the try block then
which return stetment execute.
Any one know answer for this question please give me answer
thank you
Henry Wong

Joined: Sep 28, 2004
Posts: 20514

First of all, please do not cross post. It wastes people's time and effort, as they may be answering a question that has already been answered. Second, please choose your forum correctly, as this question has nothing to do with threads.

Anyway, since one of the other threads seems to be moved to the correct forum, I will close this one.


Books: Java Threads, 3rd Edition, Jini in a Nutshell, and Java Gems (contributor)
I agree. Here's the link:
subject: try catch and finally blocks
It's not a secret anymore!