Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

multiple checkboxes

Status
Not open for further replies.

bboult10

MIS
Joined
Nov 9, 2001
Messages
6
Location
CH
Hi All,

I hope you can help me here. I'm stumped. I have form that outputs rows from a query. I want to have a checkbox associated with each row where I can select specific rows and update a table with the seleted data when i press a submitt button. Would anyone have any suggestions?

Thanks
 
Hey bboult10

Try this out. I don't have time to check for errors but this is the idea:

<input type=&quot;checkbox&quot; name=&quot;updateme&quot; value=&quot;Name&quot;>Name
<input type=&quot;checkbox&quot; name=&quot;updateme&quot; value=&quot;Email&quot;>Email
<input type=&quot;checkbox&quot; name=&quot;updateme&quot; value=&quot;Phone&quot;>Phone

because they are all named the same if multiple boxes are checked the form variable sent to your app will have all values included, so you will end up with a comma deliminated list of field names like
&quot;Name,Email,Phone&quot;

you can then loop through them as a list either using a case statement if each field requires special input, or you could make a dynamic list of inputs with the field names from the previous form.

Give it a try, let me know if you need more help.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top