If I close the browser I need to make user entry null.I m handling using JavaScript on before unload. I found I m facing 2 problems.for every post back onbeforeunload gets called and it making userid null. 2nd problem is I tried to use winsow .event and e.clientx<0. Here sometimes I found running good in local. But after published in server if condition not at all getting fired..