473,499 Members | 1,579 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

form.Submit() + C Sharp = ???

Hello all,

I was looking at the thread listed below. Basically, I have an HTML
page executing form.Submit() (written with Java script).

What do I need to do in order see the values in the fields of the form
on the server side. Normally (in .jsp), I would get the values on the
page and process it in a servlet. There would be tuples that would be
processed in the servlet. But I do not see how to do this in C#.

What must I do? Any help, hints or advice is greatly appreciated ;-)

TIA
Thread:
http://groups.google.com/group/micro...53984555b0e63c

Nov 17 '05 #1
3 3327
Request.Form or Request.QueryString collections are what you are looking for
depending on the forms method (get or post).

--

Derek Davis
dd******@gmail.com

"milkyway" <d0******@hotmail.com> wrote in message
news:11**********************@g43g2000cwa.googlegr oups.com...
Hello all,

I was looking at the thread listed below. Basically, I have an HTML
page executing form.Submit() (written with Java script).

What do I need to do in order see the values in the fields of the form
on the server side. Normally (in .jsp), I would get the values on the
page and process it in a servlet. There would be tuples that would be
processed in the servlet. But I do not see how to do this in C#.

What must I do? Any help, hints or advice is greatly appreciated ;-)

TIA
Thread:
http://groups.google.com/group/micro...53984555b0e63c

Nov 17 '05 #2
Thanks for the info ;-)

But where do I put these commands? In page_load functionality of
..aspx.cs file? Is not the page_load associated with initializing the
HTML with data (i.e. I thought that you would use this area to fill in
the fields of the HTML before they are displayed).

For me, I just wish to retrieve the contents of the screen of a form.
The form is sent to the server by using form.Submit() command.

Nov 17 '05 #3
Add this to page_load:

if(IsPostBack)
{
//do whatever with the form data here
string firstName = (string) Request.Form["firstName"];
}

--

Derek Davis
dd******@gmail.com

"milkyway" <d0******@hotmail.com> wrote in message
news:11**********************@g49g2000cwa.googlegr oups.com...
Thanks for the info ;-)

But where do I put these commands? In page_load functionality of
.aspx.cs file? Is not the page_load associated with initializing the
HTML with data (i.e. I thought that you would use this area to fill in
the fields of the HTML before they are displayed).

For me, I just wish to retrieve the contents of the screen of a form.
The form is sent to the server by using form.Submit() command.

Nov 17 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
5741
by: monika | last post by:
hi ... I have an asp page which has 3 buttons. <p align="center"><input class="button" type="button" onClick="location='welStudent.asp';" value="Click to write a new story"></p> <p...
2
5535
by: Matt | last post by:
Can form.submit() submit another form? In the following example, in page1.asp, it is fine to submit the current form: form1.submit(), and and I could see the value "Joe" in page2.asp. However, if I...
15
6538
by: M Smith | last post by:
I have a form I want to submit to itself. I want to be able to type in a list of numbers and submit the form and have that list show up on the same form under the text box I typed them into and...
4
9280
by: Stuart Perryman | last post by:
Hi, I have the following code which works just fine in IE6 but not in Firefox. It is an extract of several table rows each with an individual form. It is generated by php. <form...
5
8393
by: rjames.clarke | last post by:
I have the following. $result=mysql_query($sql); $nrows=mysql_num_rows($result); for ($i=0;$i<$nrows;$i++) { $row_array=mysql_fetch_row($result); echo "<form name='testform'...
5
17673
by: Navillus | last post by:
Hey gang, I have a login form that is empty by default, but can be filled with values from a previous form: <input type=text maxlength="40" size="40" name="user" value="`usr`"> <input...
1
10765
by: gbezas | last post by:
Hi All, I have added an event handler to redirect form.submit() to a newSubmit() method that I have defined (which does some additional processing before submitting the form). Additionally I...
3
1742
by: mirianCalin | last post by:
the code saves the category, image title, image, and feature.. but the problem is that the "feature" is not saved, but the others were saved.. this is the data types of my table category = text...
5
4997
by: nktt3514 | last post by:
I'm using a assembly to load my apllication, and now I need to list all forms in my apllication and list all controls. I have read the topic on...
0
7220
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
6893
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7386
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5468
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
4918
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4599
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3098
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
1427
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
0
295
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.