Monday 19 October 2015

How to handle exception in JSP?

Ans: Friends, There are two ways to handle exception in JSP.

1.) errorPage
2.) isErrorPage

1.) errorPage: In case of error page you have to mention the jsp file name where you want to handle the exception.It means you do want to handle the exception on same page.

Syntax: <%@ page errorPage="sharma.jsp"%>  where sharma.jsp is a another jsp file where you handle your exception.

2.) isErrorPage: It works on value.It has two values true and false.If you use true value it means the page you are mentioning this property will also handle exception code.It will not transfer control to any other page.
Syntax: <%@ page isErrorPage="true"%>

1 comment:

  1. zeed slot168 ของพวกเรา วันนี้สามารถ ช่วยเพิ่มเดิมพันที่เหมาะสมที่สุด ให้กับนักร้องเพลงทุกคน pg slot สำหรับเพื่อการเลือกเข้าใช้บริการตรงนี้ กันแน่ๆ ค้ำประกันได้เลยว่าการสร้างรายได้

    ReplyDelete