| | |
error messages
Please support our Java advertiser: Programming Forums - DaniWeb Sister Site
![]() |
try{
// code that you want to run
}
catch(NullPointerException nEx){
// what you want it to do or show when a nullpointerexception occurs
}
catch(Exception ex){
// what has to be done in case of another exception
}
a more simple form (the simplest) of this structure is:
try{
// actual code
}
catch(Exception ex){
// what has to be done in case of any exception
}
// code that you want to run
}
catch(NullPointerException nEx){
// what you want it to do or show when a nullpointerexception occurs
}
catch(Exception ex){
// what has to be done in case of another exception
}
a more simple form (the simplest) of this structure is:
try{
// actual code
}
catch(Exception ex){
// what has to be done in case of any exception
}
![]() |
Similar Threads
- internet explorer error messages (Web Browsers)
- Error messages on startup XP (Windows NT / 2000 / XP)
- Error messages aplenty!!!!! (C++)
- Microsoft Error Messages (IT Professionals' Lounge)
- Error messages pls help (MySQL)
- Wierd error messages with calculator program (C++)
- program w/ switch AND nested if. six error messages (C++)
Other Threads in the Java Forum
- Previous Thread: I need help on 2 programs
- Next Thread: error checking
| Thread Tools | Search this Thread |
Tag cloud for Java
addressbook android api apple applet application arguments array arrays automation binary bluetooth button calculator chat class classes client code columns component converter database draw eclipse error errors event exception file fractal ftp game givemetehcodez graphics gridlayout gui helpwithhomework html ide image inetaddress input integer j2me japplet java javaprojects jme jmf jni jpanel julia link linux list loop map method methods midlethttpconnection mobile netbeans newbie number objects openjavafx oracle php print problem program programming project projects recursion rim scanner screen server set signing size smart sms socket sort sql storm string support swing test threads time tree unlimited variablebinding webservices windows





