473,383 Members | 1,837 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,383 software developers and data experts.

Get List of Session IDs

Hi

Any one know how I get list of Session IDs, I mean all current Session IDs.
Thanks

--
-MrDotNet MCAD, MCSD
Sr. Software Engineer / Lead Architect

Nov 19 '05 #1
6 2399
on session start add the ID to an application level collection and read
that - and remove the ID on session end.

--
Regards

John Timney
ASP.NET MVP
Microsoft Regional Director

"MrDotNet" <Mr******@discussions.microsoft.com> wrote in message
news:B7**********************************@microsof t.com...
Hi

Any one know how I get list of Session IDs, I mean all current Session IDs. Thanks

--
-MrDotNet MCAD, MCSD
Sr. Software Engineer / Lead Architect

Nov 19 '05 #2
Hi John,

That I know it, I want some thing that give me complete list of session IDs?
"John Timney (ASP.NET MVP)" wrote:
on session start add the ID to an application level collection and read
that - and remove the ID on session end.

--
Regards

John Timney
ASP.NET MVP
Microsoft Regional Director

"MrDotNet" <Mr******@discussions.microsoft.com> wrote in message
news:B7**********************************@microsof t.com...
Hi

Any one know how I get list of Session IDs, I mean all current Session

IDs.
Thanks

--
-MrDotNet MCAD, MCSD
Sr. Software Engineer / Lead Architect


Nov 19 '05 #3
MrDotNet < Mr******@discussions.microsoft.com > wrote:
That I know it, I want some thing that give me complete list of session


I think he's trying to say there is no implicit way of doing this in
ASP.NET, so you will have to implement it manually if you require such
functionality.

Nov 19 '05 #4

Hi.

This requires a little more effort, though not very much.
First, create new class and make there function for saving sessionid to
database and all the needed logic too to do the database stuff. Create
another function that deletes sessionid from database (takes sessid as
an parameter). Create on more function to get the list of sessionid's
which has been saved to database.
Now, the fun part:
In global.asax you have sub "On_SessionStart". Instantiate a new object
from the class you made for saving and deleting sessionid:s.
Get first the sessionid from the current session and pass it to the
sessionid saving method in your class.
In Global.asax is also sub "On_SessionEnd".
Do exact the same, only this time you use the function that deletes the
sessionid from the database.
Now you have sessionid:s stored in the database and they gets updated
and deleted dynamically as clients enter and leave your application.
To get a list of sessionid:s in the database you have to do a listing
page to get sessionid's listed. Page could be in the same application
that your clients uses, or it can be completely aside from that
application because the data exists in the database.

Hope this helps :)

-tom-

--
tomBond
------------------------------------------------------------------------
Posted via http://www.codecomments.com
------------------------------------------------------------------------

Nov 19 '05 #5
indeed, session is private to the session. if you want to make the ID's
publically available then you have to cludge it.

--
Regards

John Timney
ASP.NET MVP
Microsoft Regional Director

"Jeff Evans" <jwevans1@you_eye_you_see.edu> wrote in message
news:e%****************@TK2MSFTNGP14.phx.gbl...
MrDotNet < Mr******@discussions.microsoft.com > wrote:
That I know it, I want some thing that give me complete list of session


I think he's trying to say there is no implicit way of doing this in
ASP.NET, so you will have to implement it manually if you require such
functionality.

Nov 19 '05 #6
Hi MrDotNet,

ASP.NET does have an option to store session state in a SQL Server
database instead of in memory. With real-time session data stored in
SQL Server, you should be able to query the SQL Server database to
determine active sessions.

http://idunno.org/dotNet/sessionState.aspx

Best,

Ross Overstreet
Overgroup Consulting, LLC
MrDotNet wrote:
Hi

Any one know how I get list of Session IDs, I mean all current Session IDs. Thanks

--
-MrDotNet MCAD, MCSD
Sr. Software Engineer / Lead Architect


Nov 19 '05 #7

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

Similar topics

1
by: Hollek | last post by:
Before users can use my asp-site, they have to login. The username is stored in a session variable "USR". I need a list of all users that are active in my site. I tried to store the logged...
3
by: L. D. James | last post by:
Can someone help me to define a format of a database, or a table that has a field that will have tables in that field? Please look at the example and explanation below: Table: Roster ...
13
by: Leszek Taratuta | last post by:
Hello, I have several drop-down lists on my ASP.NET page. I need to keep data sources of these lists in Session State. What would be the most effective method to serialize this kind of data...
7
by: segue | last post by:
For an asp.NET app. I have a list that I want to keep in memory. My choices are keeping the list in an asp.NET listbox control, session object, database, xml file. This list has values that...
4
by: maglev_now | last post by:
I'm using .net 1.1 trying to get a list of files in folder on the server. The user would select the file they want to download from a DropDownList. Can someone tell me how this should be done? I...
0
by: Pieter | last post by:
Hi, I'm using NHibernate 1.2 (CR1), and I'm using a custom list (inherited from BindingList(Of T) ) for all my lists. The NHibernate documentation told me that I had to implement...
0
by: Jeff | last post by:
ASP.NET 2.0 My webpage has a GridView showing rows from a table in the database. All these rows are stored in the session object -what's actually stored is generic list of objects, as this:...
0
AmberJain
by: AmberJain | last post by:
Windows Autorun FAQs: List of autostart locations Linked from the Original article- "Windows Autorun FAQs: Description". Que: Can you list all the autostart locations for windows? Ans: Here is...
0
by: c0mrade | last post by:
I have a problem with getting the list items, below is my hibernate code, after that code there is my method ..and below that is my junit test. How can I make sure that query is executing properly,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

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.