P
PABruceFan
I am dynamically adding rows to an asp:table as a result of a database
query. The row consists of a label, a textbox and three checkboxes in
that order:
LABEL TEXTBOX CHECKBOX1 CHECKBOX3 CHECKBOX2
name1 email1 checked checked checked
name2 email2 not checked checked checked
I have no problem adding the dynamic controls...
Now, suppose the user clicks on name2/checkbox1 and changes the state
to checked then hits the submit button...I need to write this change
to my database. The problem is that since the controls are dynamic,
there are no page variables that I can access to determine the new
value. To obtain the value I do the following:
string state = Request.Form.Get( "Row2_CheckBox1" );
There is no problem with this and it works fine, it just seems like it
NOT the ASP.NET way of doing things. Is there a better, more ASP.NET
way of doing things?????
TIA-
Barry
query. The row consists of a label, a textbox and three checkboxes in
that order:
LABEL TEXTBOX CHECKBOX1 CHECKBOX3 CHECKBOX2
name1 email1 checked checked checked
name2 email2 not checked checked checked
I have no problem adding the dynamic controls...
Now, suppose the user clicks on name2/checkbox1 and changes the state
to checked then hits the submit button...I need to write this change
to my database. The problem is that since the controls are dynamic,
there are no page variables that I can access to determine the new
value. To obtain the value I do the following:
string state = Request.Form.Get( "Row2_CheckBox1" );
There is no problem with this and it works fine, it just seems like it
NOT the ASP.NET way of doing things. Is there a better, more ASP.NET
way of doing things?????
TIA-
Barry