if not possible, then how do i display an user defined msg when one of the 2 exceptions is caught?
Printable View
if not possible, then how do i display an user defined msg when one of the 2 exceptions is caught?
Catch two exceptions separately. But you should catch the upper level exception later. Read more about exception handling on Suns' tutorial. You can have a clear idea about that.
Lesson: Exceptions (The Java™ Tutorials > Essential Classes)