checkboxlist problems
hello,
let me try to explain my problem clearly, my english is not perfect. :)
Im doing a little experiments with asp.net 2.0 while im reading the book "beggining Asp.net 2.0".
This is my problem:
If i use a simple checkbox i have no problem, everything is fine, writing great to the database:
<asp:ControlParameter Name="primeira_vez"
ControlId="Checkbox1"
PropertyName="Checked"
Type="Boolean" />
but now i want to use the CheckBoxList, i retrieve my checkbox items from a database table (5 items, no problem here) but how to write it to the database, i have something like this for each checkboxlist:
<asp:ControlParameter Name="field1"
ControlId="cblRendimentos" --->cblRendimentos is my checkboxlist
PropertyName="SelectedValue"
Type="String" />
<asp:ControlParameter Name="field2"
ControlId="cblRendimentos"
PropertyName="SelectedValue"
Type="String" />
...
the problem is that it only saves to the database the last click (if i clicked the 4th element and do the insert all 5 fields related to checkboxlist have 4 saved in it, like a group)
Hope you understand my problem, try to help me, a really would apprecciate that.
Greetings from Portugal
|