Click here to Skip to main content
15,073,282 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Which is the best way for store value in a variable which must be distinct for all user who are using the web application in asp.net?
Posted

1 solution

The 'Global.asax' file is designed for handling global application variables for the whole website. Read more: Application wide variables or globals in asp.net[^]
   
Comments
Sandip Paul 491984 11-Mar-14 7:24am
   
ImageButton btndetails = sender as ImageButton;
GridViewRow gvrow = (GridViewRow)btndetails.NamingContainer;
Session["clientid"] = Convert.ToInt32(ClientDet.DataKeys[gvrow.RowIndex].Value);

is the session["clientid"] value is equal for all user who click the gridview or it id different for all user.I am little bit confuse please help me.
Peter Leow 11-Mar-14 7:43am
   
No, each user will get his own unique copy of the session["clientid"] the value of which is determined solely by the ClientDet.DataKeys[gvrow.RowIndex].Value at that point of time in that user's session.
Find out more: http://www.codeproject.com/Questions/175770/Difference-between-Application-and-Session-State

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)




CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900