- Where Developers Learn, Share, & Build Careers
I have If I keep it like this: Can I be able to pass the value of textbox1 to the code behind a specific method, if so, such as, a received variable? I mean, how can I get the value of textbox 1? By the way, I am trying to do this before landing the page. Because I need to store text from TextBox 1, so that I can allocate the value again after page refresh. You can get value back to post using 'form' as 'back'. and if you request this Comments . In Asp.net, we usually use the directly document.form1.submit () in javascript. I want to know how it got behind this code. In which class, in which method? something like that. Coz I want to get the value inside a text box to store it in one session. And do I need a real "submit" button for this? It really confuses me.
function callSubmit () {var thetext = document.getElementById ('textbox1'). Value; Document.form1.submit (thetext); }
request. Form ["textbox 1"]
. Read the form You get all the data from the post
request form. and we use asp.net controls that handle all ready post values. For example, if you use
asp: textbox by
id = text box 1 then you can read the post from
textBox1.Text and if you want to If you want to read it using
Request.Form , you must call
request.form [textbox1.UniqueID]
textBox1. UniqueID is the
name value on the html control, and the names used for the post.
Comments
Post a Comment