Puzzled? How to re-assign object reference of web control in ASP.NET
1) I have a web server control, lets say TextBox1 (System.Web.UI.WebControls.TextBox) declared (not dynamically created in code behind) inside a form on my aspx page
2) This control has the runat="server" attribute
2) Inside the PageLoad event I dynamically create another TextBox control (TextBox2) and set its Text property to some text "My New Text"
3) Still inside the PageLoad event I try set TextBox1 = TextBox2
4) Now that TextBox1 points to TextBox2 I look at the value of the Text property on TextBox1 (in the Watch window) and see that it is equal to "My New Text"
5) Great so far... Not so fast. When the page gets rendered TextBox1 does not contain the string "My New Text"
6) HOW COME????