Click here to Skip to main content
15,889,629 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
Dear Experts !!

Am working on ASP.Net , C#, SQLServer 2005.

I have Created a Web Application, and Finally Hosted in IIS Server.

After hosting in server,I can Login with Same Username and Password from Different systems.

So how to avoid these login.... one username and password from other systems.

Suppose if i login from one System and if i use these same username and password. it must show a message that....already login with this username.


Note : No Same User should login.....if the other user already login with same username/password.

Please help me this problem.

Thanks
Posted

Basically, you have to save a flag in your database that says "user logged in" and check it when the same user tries again, and refuse it.

It would be a good idea to put a timeout on this (so that your user can log in again after he has been idle for half an hour say) so that a power failure or similar does not leave you user permanently unable to get in.

The exact details are up to you - we do not know anything about what login system you are using!
 
Share this answer
 
hi Ranjith,

you can add one more field in logindetail table where you save loginid and password,field is IsLogin boolean type.

this field should false default.when user login this field is updated to true.
on every login check is true or false if true that means user already login.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900