Display user input from a textbox into a label
how can i Display user input from a textbox into a label in another page in c#
4 Answers
Know the answer? Post it. Somebody with the same question will find it here.
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Jignesh TrivediRank #16 · 50.3K reputationPosted Jun 20, 2013, 6:59 PM EDT
Are you using winform application or web base?
if you are using winform than this value can be pass through Constructor of another form.
and if you use web application than you can pass this value using query string or other state managment.
hope this will help you.
Pankaj PandeyRank #642 · 3.7K reputationPosted Jun 20, 2013, 9:19 PM EDT
Session["a"]=textbox1.Text;
on another page write on page load event
if(Session["a"]!=null)
{
label1.Text=Session["a"].ToString();
}
amr kamal35 reputationPosted Jun 21, 2013, 11:32 AM EDT
amr kamal35 reputationPosted Jun 21, 2013, 11:33 AM EDT