Try using

Code: Java
try
{
  //
}
catch(e)
{
  //
}
finally
{
  // your code here
}