Problem with the ViewState of a TextBox

  • Thread starter Thread starter Andrés Giraldo
  • Start date Start date
A

Andrés Giraldo

Hi!

I'm adding rows dinamically to a System.Web.UI.WebControls.Table, on
depends on a dropdown listbox's selected item, on a Cell of the table
I'm adding a TextBox, it's Text property it's a column of a DataSet
filled on depends of the listbox's selected item... But I have the
following problem:

When I select a second item on the dropdown list, the text of the
textboxes are the same, even when in debug time, it shows me another
values, the right values... it keeps it's first values...

The proble are the TextBoxes, because, I replace them with Label
controls or another control, and it works fine, but if I use an
HtmlInputText, or a TextBox, the error occurs...

I tried to set the EnableViewState property of the TextBox to False, and
it doesn't works...

somebody could give me an idea of what's happening?

Thanks!
 
Andres,

Use the debugger to step through your code. It sounds as if you are once
again repopulating the text boxes based on the first drop down change even
after the second.

Sincerely,

--
S. Justin Gengo, MCP
Web Developer

Free code library at:
www.aboutfortunate.com

"Out of chaos comes order."
Nietzche
 
Back
Top