J
John Bankhead
I created a user control that displays different subsets of data depending on
the value of its public property "Folder". I placed the control on my page
along with four asp:buttons to represent the four different folders. The
clicking a button fires off the folder_click function which in turn sets the
Folder property on the user control.
The situation that I had was that I would not see the folder change until
there were two round-trips to the server. The data that shown was always one
click behind.
To fix this, I placed the line: this.ChildControlsCreated = false; in the
set section of the Folder property. And it worked.
So my question is: Is this what I should have done? Or is it just a patch?
the value of its public property "Folder". I placed the control on my page
along with four asp:buttons to represent the four different folders. The
clicking a button fires off the folder_click function which in turn sets the
Folder property on the user control.
The situation that I had was that I would not see the folder change until
there were two round-trips to the server. The data that shown was always one
click behind.
To fix this, I placed the line: this.ChildControlsCreated = false; in the
set section of the Folder property. And it worked.
So my question is: Is this what I should have done? Or is it just a patch?