473,804 Members | 2,747 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Posted Form Items not in Request

Hi there,
I have a pure HTML form that is submitting data back to an
..ASPX form. However, when I try to read the field values from the Request
object, the values are not there.

The Form has id, method and action set. The fields have ids, but when I do
something like:

String avar = Request["FieldId"];

I only ever get null returned. What am I missing?

Regards,

Steve W.
Apr 8 '08 #1
2 1133
If you are not using .NET controls then you need to use name not id....

Like <input type="text" name="txtUser">
then Request["txtUser"] will work

Also they must be inside of <form</formtags.

PS: You can always check in debugger Request.Forms collection to see what is
being submitted.

George.
"Waldy" <so*****@micros oft.comwrote in message
news:%2******** ********@TK2MSF TNGP06.phx.gbl. ..
Hi there,
I have a pure HTML form that is submitting data back to an
.ASPX form. However, when I try to read the field values from the Request
object, the values are not there.

The Form has id, method and action set. The fields have ids, but when I
do something like:

String avar = Request["FieldId"];

I only ever get null returned. What am I missing?

Regards,

Steve W.

Apr 8 '08 #2
"George Ter-Saakov" <gt****@cardone .comwrote in message
news:Oa******** ******@TK2MSFTN GP02.phx.gbl...
If you are not using .NET controls then you need to use name not id....

Like <input type="text" name="txtUser">
then Request["txtUser"] will work

Also they must be inside of <form</formtags.
Thanks George, that was it.
Apr 8 '08 #3

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

Similar topics

15
13354
by: Håkan Persson | last post by:
Hi. I am trying to set up a simple HTTP-server but I have problems reading data that is beeing POSTed. class httpServer(BaseHTTPServer.BaseHTTPRequestHandler): def do_POST(self): input = self.rfile.read() The self.rfile.read() will hang on the
9
2409
by: Brian Burgess | last post by:
Hi all, Anyone know of any issues with setting the value of a Session object to the value of a submitted form item via 'Session("mySessionObj")=Request.Form("myFrmElem")' ? In my case the Session object gets set fine. But when the user links to another page, the value of the session object is EMPTY. thanks in advance..
2
4084
by: Nick | last post by:
Loop to create an array from a dynamic form. I'm having trouble with an application, and I'll try to explain it as clearly as possible: 1. I have a form with two fields, say Apples and Oranges. The user selects from a drop down menu, between 1-10 of each and clicks submit. The resulting page will display a NEW form, with rows and a list of fields for the amount of each items selected.
1
392
by: Kathy Burke | last post by:
HI. in asp.net app, I have an xmlDocument that I transform to the client html. Using xsl I create a few textboxes to capture user input. Each of these are related to <data> elements in the xmlDoc. I want to use the Forms collection to post the html form back to an asp.net page, and process each request.form object (textbox) via an xml node.value update. For any given xmlDocument there is an unknown number of items resulting in...
10
3480
by: Mr Newbie | last post by:
DropDown lists and Listboxes do not appear in the list of controls and values passed back to the server on PostBack in Request.Form object. Can someone confirm this to be correct and possibly answer why ? The impact of this is that values added via javascript will never make it back to the server side code unless one does some jiggery pokery with hidden fields etc. If this is true, then I would like to understand the reason behind the...
1
7308
by: Daniel Gormley | last post by:
What I have is a form that is dynamically generated based on which database table its calling. Therefore, the number of category.name.count can be different. So I have this form generated and say with x amount of input boxes.. I enter data in the boxes and submit. The data submitted is needing to be placed into an array for insert into a database.
2
1287
by: Roshawn | last post by:
Hi, On my asp.net page I have an html form. I've set runat attribute to server and filled it with server controls. All settings are as I like them. So here's the problem: when I perform a search for the first time, everything works perfectly. If I make any changes to the controls in the form and resubmit the page, nothing changes. That is, viewing the querystring, not a single value is altered despite my doing so in the form itself....
20
19269
by: Mr. SweatyFinger | last post by:
I'll never understand this for each ?? in request.form.items response.write ?? next what the heck is ?? and how do yo dim it? can it be any name?
3
2844
by: jerry101 | last post by:
Okay, so I have no knowledge with ASP and I was asked to look at this contact form because the emails aren't delivering. I'll post the whole page of code, because I am unsure at what is what really apart from the common knowledge stuff i.e. the send email to etc, but this wasn't designed by me so I am unsure if it's wrong or right.. If someone could let me know whether there's a problem with the code or if the problem may lay elsewhere...
0
9711
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9591
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10594
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
10331
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10087
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
5529
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 last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
4306
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 we have to send another system
2
3831
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3001
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 can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.