title: Prevent multiple login
body: <p>I am creating an application where users <strong>cannot attempt multiple logins.</strong> If a particular <strong>user logs in</strong>, my <strong>database</strong> flag <strong>value</strong> becomes set to <strong>1</strong> that means no other member who has the same username and password can login. </p>
  
  <p>If a user <strong>signs out</strong> my <strong>database flag value is set to 0.</strong> That's all working fine but now I have one different <strong>problem</strong> that is when a <strong>user suddenly closes the browser without logout page</strong> or <strong>session is timeout</strong> then automatically the database flag value should be set to 0. </p>
  
  <p>I am searching about this some articles said it can happen using global.asax file. I tried it but nothing happend so far. Please can you help me?</p>