In asp.net, It is very simple to detect session time out and redirect the user to login page or home page.All you have to do is, specify the redirection page in session_start event handler in Global.asax file as shown below.
void Session_Start(object sender, EventArgs e)
{
Response.Redirect("LoginPage.aspx");
}
If the session has timed out, the user will be redirected to the login page. Adding this code snippet, you do not have to worry about session and so no session check.