mr_medhat
Posts: 16
|
Posted: 07/14/2006, 7:10 AM |
|
This link show how to have a session variable with ASP or PHP ,,,
http://docs.codecharge.com/studio3/html/ProgrammingTech...iables.html?toc
How can I keep a session variable after logging in using VB.NET ?
Thanks ,,
|
|
|
Diesel
Posts: 43
|
Posted: 07/17/2006, 8:30 AM |
|
Hi
This is the equivalent to setting a Session Variable in .NET
System.Web.HttpContext.Current.Session("User_Name")=CType((New TextField("",Settings.Connection1DataAccessObject.ExecuteScalar("SELECT " & "User_Name" & " FROM " & "Users" & " WHERE " & "User_ID=" & Item.User_Id.Value))).Value, String)
Hope it helps
Regards
|
|
|
mr_medhat
Posts: 16
|
Posted: 08/24/2006, 11:41 AM |
|
Hi Diesel ,
No , This code doesn't fully work ,
If I replace the Part of "Item.User_Id.Value" with a specific ID value , the code works fine , but if it remains as is , I get the error :
'User_Id' is not a member of 'School_1.Logon.LoginItem'
Any Ideas !!
Thanks in advance
|
|
|
|