There is very easy work around.
First of all you make your textbox ReadOnly = false;
but you add
textBox.Attributes.Add("readonly","true");
That is all.
No I didn't try this on regular pages.
Let me know if it works differently on pages.
Shimon.
"Mr Newbie" <he**@now.com> wrote in message
news:OS**************@TK2MSFTNGP09.phx.gbl...
Thats a shame as I used to use this, have you also tried this on normal
pages ? You could of course work around this by saving the value manually
to viewstate
--
Best Regards
The Inimitable Mr Newbie º¿º
"Shimon Sim" <sh**********@community.nospam> wrote in message
news:Ox*************@TK2MSFTNGP10.phx.gbl... Found. For some reason if you set a TextBox ReadOnly = true. It doesn't
keep stateview. In 1.1 behavior was different
"Shimon Sim" <sh**********@community.nospam> wrote in message
news:eQ**************@TK2MSFTNGP11.phx.gbl...I am working with ASP.NET 2.0
I have user control that has 2 textboxes. On of them is hidden using
html attribute (it is still rendered on the page). The control also has
html button for JavaScript event.
After user clicks on the button browser shows pop up web dialog and
allows user to make select in it. The selection that is displayed in the
visible textbox and key of the selection is stored in hidden text box.
The problem is that after post back and page returns to the browser the
values of the boxes are lost. ( I can read them on server though). I
don't have anything clearing them.
Any ideas? All the EnableViewState set to true (two textbox and the
usercontrol on the page)
Thank you,
Shimon.