Session variables inside shared functions

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello,

My question is simple.

If Session variables were to be assigned a value inside a shared function,
does the session data visible to other sessions (Other users). I know the
variables used inside the shared function are shared as well, is it same for
session variables...?

example vb.net;

class test
public shared SharedFunction (byVal EmployeeID)
HttpContext.Current.Session("EmployeeID")=EmployeeID
return true
end sub

the above shared class is called from code behind.

//Inside Button Submit code, code behind
test.SharedFunction("Bill")

Will the value "Bill" visible bind to the user session or visible all acrosss?

Thanks
 
Session variables will not be visible to other sessions.

Eliyahu
 

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

Back
Top