473,563 Members | 2,856 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Single User Login At A Time

Hi,

Does anyone knows how to control user login that only a single userid can
login at a time?

Thanks

Joey
Nov 19 '05 #1
3 3930
You could store the ID of all users in an Application variable or a database
and check if that one is in use. Of course you'd need to make sure the
person logged out properly so you could remove the ID.

"Joey Lee" <jo*********@ho tmail.com> wrote in message
news:O5******** ******@TK2MSFTN GP10.phx.gbl...
Hi,

Does anyone knows how to control user login that only a single userid can
login at a time?

Thanks

Joey


Nov 19 '05 #2
Thank. Actually that is the problem which i am currently facing. I keep the
userid in the cache and do checking. But if the user just click on the "x"
button closing the browser. he will be log out until the cache expire or my
undetermined session_end method in global.asax fires to kill of the
information in cache.

Is there a better way??

Joey
"Ken Cox [Microsoft MVP]" <BA************ @sympatico.ca> wrote in message
news:ee******** *****@TK2MSFTNG P09.phx.gbl...
You could store the ID of all users in an Application variable or a
database and check if that one is in use. Of course you'd need to make
sure the person logged out properly so you could remove the ID.

"Joey Lee" <jo*********@ho tmail.com> wrote in message
news:O5******** ******@TK2MSFTN GP10.phx.gbl...
Hi,

Does anyone knows how to control user login that only a single userid can
login at a time?

Thanks

Joey

Nov 19 '05 #3
This is a very common problem. Too bad that there isn't a standard HTML tag
that allows something like this:

<ONCLOSE href=http://mysite.com/logout.aspx />

I'm not sure if JavaScript can handle this. Downside of JavaScript is that
it can be disabled by the user, or unsupported by browser. I think and
<onclose> html tag should've been part of standard html.

Since it isn't, I think using timeouts is the only way. You can try limiting
the timeout to 5 minutes, and every time there is activity on the webpage,
you reset the timer. This means if the user stares at the same page for 5
minutes, the login session expires.
This could be eased with a JavaScript code that calls a
http://mysite.com/keepalive.aspx, to reset the timer.

Lisa
"Joey Lee" <jo*********@ho tmail.com> wrote in message
news:ec******** ******@tk2msftn gp13.phx.gbl...
Thank. Actually that is the problem which i am currently facing. I keep
the userid in the cache and do checking. But if the user just click on the
"x" button closing the browser. he will be log out until the cache expire
or my undetermined session_end method in global.asax fires to kill of the
information in cache.

Is there a better way??

Joey
"Ken Cox [Microsoft MVP]" <BA************ @sympatico.ca> wrote in message
news:ee******** *****@TK2MSFTNG P09.phx.gbl...
You could store the ID of all users in an Application variable or a
database and check if that one is in use. Of course you'd need to make
sure the person logged out properly so you could remove the ID.

"Joey Lee" <jo*********@ho tmail.com> wrote in message
news:O5******** ******@TK2MSFTN GP10.phx.gbl...
Hi,

Does anyone knows how to control user login that only a single userid
can login at a time?

Thanks

Joey


Nov 19 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
1841
by: Tom | last post by:
I am trying to establish an infrastructure whereby I want only one login screen for my .net application users. In my experience, if the user's domain is different than the application domain, the user is presented with the Windows login screen a second time. Is it possible for the browser to pass credentials from one domain to the next?
1
1520
by: Cowboy \(Gregory A. Beamer\) | last post by:
Quite a few months back, I was able to create a single sign on app for all apps on a single box (perhaps a domain, but never tested) by setting the auth cookie name to an identical value: <authentication mode="Forms"> <forms name="SingleSignOn" loginUrl="login.aspx"> </authentication> I could then surf from app to app on the same box and...
2
2671
by: Yavuz Bogazci | last post by:
Hi, i have a question: I have a ASP.Net based WebApplication where Users have to Login to authenticate. I have a Desktop App wich needs the same Auth. information, too. But i have solved it in the way, that the user has to login in both Apps separate. The Users doesn't want such a solution. How can i realize a SIngleSignOn for both Apps?...
3
2047
by: Joe Fawcett | last post by:
Dear All We have an application where users login, their name/password details are stored in a table, and now we want to add a third party bulletin board that lives in its own virtual directory. Both applications are running on the same IIS. How do we authenticate users so that they don't have to sign in again without passing their name...
4
2709
by: Jai | last post by:
Hi, I have a problem related to Login System. I am developing 3 websites for some institution.Now they want that if anybody had sign up for there site1.com(say), than he or she should be able to sign in for site2.com and site3.com. hence, if user has sign up for the membership of site1.com than he/she should automicallly become the...
10
13057
by: shankhar | last post by:
Hi all, In my project there is a requirement. If a user logged in at a time since he/she logged out others are not allowed to loggin using the same user name. That is to avoid multiple logins using a account. How to do this? I had got a idea and implemented. 1. When a user logs in storing the username, ip, login time to db.
13
8639
by: Samir Chouaieb | last post by:
Hello, I am trying to find a solution to a login mechanism for different domains on different servers with PHP5. I have one main domain with the user data and several other domains that need a login to show data. I want the user to login only once when he visits any of my domains.
2
19397
by: aj | last post by:
SQL Server 2005 SP2 2005.090.3054.00 I'm trying to move master/model/msdb to a new spot. I restart SQL Server in single user mode with the "-c;-m;-T3608" startup params. When I try to connect to do the detach, I get: Login failed for user 'sa'. Reason: Server is in single user mode. Only one administrator can connect at this time....
17
4775
by: yuvang | last post by:
Hi all I have a mdb with login name and password form. There are several login names, i defined through a table "User_login". Here the problem is at a time a single user is able to login in multible system, which i want to restrict. here is the code which i i am using for login check..... Private Sub cmblogin_Click() Static...
0
7665
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7888
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
0
8106
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7642
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
6255
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
0
5213
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3643
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3626
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
924
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.