Hi: I have a placeholder on my webform, to which I add WebControls dynamically. The controls are added and appear fine on the form. The problem I notice is that when I post the form, I can't access these controls server-side.
e.g.) If Page.IsPostBack Then ' on submit - check for value Debug.Write ph.Controls.Count ' <-- this is 0 Debug.Write Request.Form("test") ' <-- this is ok - it finds it (?) Else Dim txt As TextBox = New WebControls.TextBox() txt.ID = "test" txt.Text = "test" ' add to placeholder on form ph.Controls.Add(txt) End If Why can't I see the controls added to the PlaceHolder control? Is there a way to set the runat="server" for these added controls to force them to post back? Thanks! You can read messages from the DOTNET archive, unsubscribe from DOTNET, or subscribe to other DevelopMentor lists at http://discuss.develop.com.