S
Sri
Hi,
I need to create controls dynamically on click of a button.
When the user click on a button, I need to create a text box, dropdown
list and check box in a row. Additional row has to be created with the
controls on each click of the button. I am able to recreate the
controls each time on Page_load event by maintaining the number of rows
as a Viewstate variable. But I am not able to retain the values entered
in the textbox/dropdownlist. How to retain the values in the
dynamically created controls? I tried with having ViewState variable
for each and every control. But somehow it is not retained. Please let
me know if there is any way to achieve this.
Thanks
Sri
I need to create controls dynamically on click of a button.
When the user click on a button, I need to create a text box, dropdown
list and check box in a row. Additional row has to be created with the
controls on each click of the button. I am able to recreate the
controls each time on Page_load event by maintaining the number of rows
as a Viewstate variable. But I am not able to retain the values entered
in the textbox/dropdownlist. How to retain the values in the
dynamically created controls? I tried with having ViewState variable
for each and every control. But somehow it is not retained. Please let
me know if there is any way to achieve this.
Thanks
Sri