How do you pass session values from one page to another ?
Answers were Sorted based on User's Feedback
Answer / pravesh chourasia
1.In first page set session variable. e.g.
Session ["Name"] = "Pravesh";
Here "Name" is name of session variable and "Pravesh" is
the value of session variable "Name".
2. In next page get the sesion variable. e.g.:-
string myName=Session["Name"].ToString();
| Is This Answer Correct ? | 98 Yes | 28 No |
Answer / hari
Get the value from Login Page where the Session Iniciated Like
Sesstion["UserID"]
and you may use this value on another page
Like
EnteredBy=Convert.Toint64(Session["UserID"])
| Is This Answer Correct ? | 0 Yes | 3 No |
Answer / vimal chauhan
response.redirect("requireform.aspx?"& txtbox1.text)
| Is This Answer Correct ? | 5 Yes | 15 No |
Answer / raja mohamed
request query:
response.redirect("requireform.aspx"?get=txtbox1.text);
requireform.aspx
txtbox2.text=get
server transfer:
dim my as string
m="value"
server.transfer("requireform.aspx"?get=m)
requireform:
dim t as string
t=page.request("m")
| Is This Answer Correct ? | 11 Yes | 34 No |
what is Impersonation
3 Answers Alliance One, Task Informatics,
What data type does the RangeValidator control support?
What does WSDL stand for?
To match the two different controls which control would we use ?
What is actually returned from server to the browser when a browser requests an .aspx file and the file is displayed?
Can session variables be accessed from code-behind?
what is differences between bind and eval?
What is the difference between Hash table and Array list?
Differences between VB.Net and C#, related to OOPS concepts
Can you give an example of what might be best suited to place in the Application_Start and Session_Start subroutines?
Advantage of Update Panel over Asp.net 2.0 + C#+ Microsoft Ajax 1.0
What is a server cookie?
Visual Basic (800)
C Sharp (3816)
ASP.NET (3180)
VB.NET (461)
COM+ (79)
ADO.NET (717)
IIS (369)
MTS (11)
Crystal Reports (81)
BizTalk (89)
Dot Net (2435)
Exchange Server (362)
SharePoint (720)
WCF (340)
MS Office Microsoft (6963)
LINQ Language-Integrated Query (317)
WPF (371)
TypeScript (144)
Microsoft Related AllOther (311)