How do I show who is currently in a database? As stated above this is for the client so everyone will have a username.
I thought I could do this by recording their name in a profile document on the database PostOpen event. Once they leave I wold remove their name the same way in the QueryClose of the database.
It appears to work great untill two users enter the database at the almost the exact same time. Then it only keeps the first user and ignores the second. Is their an easier and/or better way to do this?
Subject: How do I show who is currently in the database?
You can’t use a profile document because it is cached separately for each user for the duration of their session in the database, so they would see a snapshot of the profile at the time they opened the database, but if people come in or out while they are in there, they will not see those updates.
You could probably just do what you’re doing, but with a regular document.
Subject: How do I show who is currently in the database?
I tried that but no luck, when two or more accessed the document at the same time it created conflicts.
However what I did late yesterday afternoon worked great and was easy to implement…
-
I created a new form in Designer named “OnlineNow” with no fields in it, just a blank document.
-
I then had the PostOpen event of the database create a New “OnlineNow” Document in the background and save it.
-
I created a new view to show those documents with a single column set to @author (This shows a different document for each person currently in the database).
-
Then in the QueryClose event, I have simple code that looks in the new view, finds all “OnlineNow” documents that the user created and deletes them. It disappears from the view and others can actually “see” them leave the database — in real time!
Works great and there is no taxing server polls going on. Simply open the view and see who’s on the database.
Subject: How do I show who is currently in the database?
The Domino Administration client will show you this information. Server tab - Status tab - Database users.
HTH.
Subject: RE: How do I show who is currently in the database?
I should have mentioned I knew that, sorry. It needs to be done from Designer so that our users in the database can see who is in the database with them.