i want to shar som val
-
Public Shared vas As String the code shar val in all setion i want shar in one setion not all Plz help me
Ahmed El-Badry
-
Public Shared vas As String the code shar val in all setion i want shar in one setion not all Plz help me
Ahmed El-Badry
-
What do you mean by section in this case? If you want the variable to be local to the object, just remove the
Shared
keyword.--- single minded; short sighted; long gone;
i want shar like cookes or send me a sample in cooke V thnx
Ahmed El-Badry
-
i want shar like cookes or send me a sample in cooke V thnx
Ahmed El-Badry
Oh, so by "setion", you mean session, not section? If you remove the
Shared
keyword, the variable will be local to the object, and therefore also local to the thread. Each request that comes to the server is handled in a separate thread. If you want to keep the value from one request to another, on a user basis, you have to use session variables or cookies.--- single minded; short sighted; long gone;
-
Oh, so by "setion", you mean session, not section? If you remove the
Shared
keyword, the variable will be local to the object, and therefore also local to the thread. Each request that comes to the server is handled in a separate thread. If you want to keep the value from one request to another, on a user basis, you have to use session variables or cookies.--- single minded; short sighted; long gone;
how use session variables give me a ex bad english sooooooooorye thnx u:rose:
Ahmed El-Badry
-
how use session variables give me a ex bad english sooooooooorye thnx u:rose:
Ahmed El-Badry
You create a session variable by adding a value to the collection:
Session["answer"] = 42;
As session variables are of type object, you have to cast them to the correct type when you read them:int answer = (int)Session["answer"];
You can remove a variable from the collection:Session.Remove("answer");
You can also remove all variables:Session.RemoveAll();
--- single minded; short sighted; long gone;
-
You create a session variable by adding a value to the collection:
Session["answer"] = 42;
As session variables are of type object, you have to cast them to the correct type when you read them:int answer = (int)Session["answer"];
You can remove a variable from the collection:Session.Remove("answer");
You can also remove all variables:Session.RemoveAll();
--- single minded; short sighted; long gone;
Thank you very much :-D:rose: to help me
Ahmed El-Badry