Please look at javascript timer -
Here[
^]
and
Here[
^].
Set it equal to your session timeout and on timeout navigate to a page that executes the logoff procedure. The user can then be redirected to wherever - the login page for example - telling them their session has expired.
Be careful of this technique if you expect the user to remain on a page for longer than the timeout.
You should back this up with code in Global.asax Session_End to perform any server side logoff processes to guard against browsers being directly closed by users.