views:

296

answers:

2

i have this requirement and since im new to vb.net dont really have much of idea how to do this. I have 20 checkboxes with dropdowns and textbox with it. the example is -

table
tr
td
checkbox -- textbox -- dropdownlist
/td
/tr
tr
td
chk1        txtbox1    ddl1
/td
/tr
tr
td
chk2        txtbox2    ddl2
/td
/tr

and so on. the above structure shall be in one row of a table. does anyone know how to design this in code recursive and also how to take the checkbox data from here and send it to db table for records insert, update and select. thanks

A: 

You can use the CheckBoxList and bind it to your data.

Here is an example

Here is another example

And here is an example on how to lay out the CheckboxList

EDIT: OK. Another example on using a Checkbox inside a repeater.

rockinthesixstring
@reder "none of the examples given by rockinthe... work". using DataBind to bind your data to a CheckBoxList is a good way of doing it. Can you post some code of what you tried?
rockinthesixstring
Ah... @Heinzi 's edit of the original question adds clarification. Why don't you try putting in an asp:repeater for your layout?
rockinthesixstring
A: 

none of the examples given by rockinthe... work

reder
you should add your comment in the comments section instead of posting a new answer.
rockinthesixstring