number of online users?

G

Guest

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

Hans Kesting

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
 
P

Patrice

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

--
 
G

Guest

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.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,774
Messages
2,569,596
Members
45,143
Latest member
DewittMill
Top