number of online users?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

how I could count the number of online users with asp .net?
which complement should i use?
 
Esref said:
how I could count the number of online users with asp .net?
which complement should i use?

Probably something like this:
- have a counter in the Application object
- on Session start increment the counter
- on Session end decrement it

This should count all active sessions, but there are some warnings:
- a session is counted until it ends, which is 20 min. after the user has left your site
- I read somewhere (can't remember the link - can someone confirm?)
that Session_OnEnd is not called if nothing was stored in the session.

Hans Kesting
 
Another option is to read the corresponding performance counter (and perhaps
cache the value as there is probably no need to have alwxays the exact
value)...

Patrice

--
 
Can you tell me how I can read this performance counter?
The global.asax way seems not to work on my server.
 
By the way I am using C# and the global.asax is VBScript. could this be the
problem why this is not working?
If I use the same code in VB on my page than it does work.
 
Back
Top