Dynamic checkboxes and selection

S

sck10

Hello,

I have a list of products (SQL Server) that I need to show with check boxes
next to them. Once they submit the form, the items checked will be inserted
into a table. I think I need to use a CheckBoxList, but how do I show what
has been matched in the future. For example, I check 5 of the 10 products
for a particular customer. When I edit that customer's information, I want
to show the 10 products with the 5 products that I check previously to be
checked.

Any help with this would be appreciated...
 
F

Fernando Rodriguez

You need to iterate through the collection of items and set the Checked
property to true for the ones that you want checked.

You can also use a Repeater or a DataView with a checkbox column and bind
the checkbox's Checked property to a field on your datasource.
 
S

sck10

Thanks Fernando,

sck10


Fernando Rodriguez said:
You need to iterate through the collection of items and set the Checked
property to true for the ones that you want checked.

You can also use a Repeater or a DataView with a checkbox column and bind
the checkbox's Checked property to a field on your datasource.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,055
Latest member
SlimSparkKetoACVReview

Latest Threads

Top