try catch?

does the try catch function means that the program try to do something and if an error occured then the program will not do anything? correct me if im wrong please
[177 byte] By [w32sysfiea] at [2007-11-27 3:28:24]
# 1
The try-block is a high wire your program balances on, the catch block is the safety net. The program executes the try block as far as it can. If it fails, it'll drop off at some point and land in the safety net. If it succeeds, the net isn't used.
CeciNEstPasUnProgrammeura at 2007-7-12 8:31:14 > top of Java-index,Java Essentials,New To Java...
# 2
so powerful languange
w32sysfiea at 2007-7-12 8:31:14 > top of Java-index,Java Essentials,New To Java...
# 3

but why some codes need to use try catch?

for example

try

{

UIManager.setLookAndFeel(getSystemLookAndFeelName());

SwingUtilities.upadateComponentTreeUI;

catch(Exception e)

{

}

why?

w32sysfiea at 2007-7-12 8:31:14 > top of Java-index,Java Essentials,New To Java...
# 4
> why? http://java.sun.com/docs/books/tutorial/essential/exceptions/
sabre150a at 2007-7-12 8:31:14 > top of Java-index,Java Essentials,New To Java...