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 |
Which is faster viewdata or viewbag?
Explain swagger components.
Explain the differences between managed and unmanaged code?
Which institute provide good Project training on .Net technologies in hyd?
I have a datagrid of 10 rows and I am updating the fifth row using template column edit. How wil u know that the row is updated, so that it can be send to database for updating the respective table?
How to change Master page in ASP.Net using code?
What is asp according to you?
What are cookies in your browser?
Describe a bubbled event and how it is used ?
What is the function of the CustomValidator? a) It allows for custom C# client-side code to validate entries in a control. b) It allows for a custom mixture of validator controls to use one central control for the display of messages. c) It uses scripted client-side code to validate the entry in a control. d) It uses server-side code to validate the entry in a control.
4 Answers ABC, Syntax Softtech, TCS,
What is Difference between Production Serves and Development Servers? And Suppose, m adding/deleting C# file in a project based on the Specific Requirement. These Files are Automatically updated in Production Servers? So Which tool is needed to do This One?
What is use of <% %> in asp.net?