473,396 Members | 2,021 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

ASP Form Array - Delimiter Problem

Thanks to Ray Costanzo [MVP] for the solution
here is the C# version working sample

Expand|Select|Wrap|Line Numbers
  1. <%@ page Language="c#" AutoEventWireup="false"   TargetSchema="http://schemas.microsoft.com/intellisense/ie5"%>
  2. <%Response.Write("Hello");%>
  3.  
  4. <form name="test" method="post">
  5. <input type="text" name="one"><br/>
  6. <input type="text" name="one"><br/>
  7. <input type="text" name="one"><br/>
  8. <input type="text" name="one"><br/>
  9. <input type="submit" value="one"><br/>
  10. </form>
  11.  
  12. <%
  13. if(Request.HttpMethod =="POST")
  14. {
  15. foreach(string q in Request.Form.GetValues("one"))
  16. {
  17.     Response.Write ("One of the values: " + q + "<br>");
  18. }
  19. }
  20.  
  21.  
i had been struglling with this problem for a long time as Request.Form.Get(varname) gives comma separated values which is fine as long as the value itself does not contain a comma.
Oct 31 '07 #1
0 750

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: nospam | last post by:
If I had a text file with the following two columns: key1 value1 key2 value2 key3 value3 How would I read in this file and create an associative array?
12
by: Sam Collett | last post by:
How do I remove an item with a specified value from an array? i.e. array values 1,2,2,5,7,12,15,21 remove 2 from array would return 1,5,7,12,15,21 (12 and 21 are NOT removed, duplicates are...
2
by: rhungund | last post by:
Hey all... I'm submitting various form variables as arrays, so when I do try to access them when the form is submitted, i do a split on the variable and pop it into an array. for example:...
9
by: Steve | last post by:
Hello (and a happy new year) I'm quite new to C++ and have to programm something for school and can't get my head around a couple of things, but at the moment this one is the most important for...
2
by: Mark Hannon | last post by:
I am trying to wrap my brain around storing form elements inside variables & arrays before I move on to a more complicated project. I created this simple example to experiment and as far as I can...
2
by: Microsoft | last post by:
I'm not sure which control to use for this: I would like the user to be able to paste a list of items into a box and then be able to run through them one at a time. Hopefully there is a control...
7
by: Felix85 | last post by:
I am trying to make a command interpreter for a mud that i am working on the problem i am having right now is that i cannot convert the string into a char array. This is the error I am getting...
3
by: empiresolutions | last post by:
Hello, I'm trying to get this script to work, but my deep rooted PHP syntax is messing my JS up. I have a flash file that calls this JS function. It basically adds a number to a comma...
7
by: bcap | last post by:
hi, I am trying to create a form where you may have more than one person at a meeting, but want to have them be related to the same meeting. I have a mulitple select text area and if you...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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...
0
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,...
0
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...
0
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,...

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.