petre ricardo

petre ricardo

  • NA
  • 194
  • 0

How to extract values from a Dictionary based on SessionID?

Oct 26 2009 6:38 PM

hi,
I;m using a Dictioanry collection to store FirstName using SessionID as key. then i store it in a session object. I need to extract the first Name from the user's home page.
 

Button_Click()
{
   Dictionary<string, string> firstNames = new Dictionary(stirng, string)();
   Session.add("FirstNames", null);
   DataTable dt = obj.Authenticate(user, pass);
 
   string strSessionID = Session.SessionID;
 
   foreach(DataRow row in dt.Rows)
   {
      firstNames.Add(row, strSessionID);      
   }
 
   Session["FirstNames"] = firstNames;
 
}

 
How do i search the FirstName based on the sessionID from the user's home page? (this is an issue when there are more than one user logged in to the server)
TY
 
Problem is how do i pass the sessionID to the user's home page

Answers (2)