"SSW" <fr************@hotmail.com> wrote in message
news:eH**************@tk2msftngp13.phx.gbl...
U need to have a Place holder or Panel to add control.
Dim txt as new System.Web.UI.Webcontrols.Textbox()
PHtxt.Controls.add(txt)// where PHtxt is PlaceHolder web controls
No, you shouldn't need a placeholder or panel. I add controls to pages all
the time without placeholders.
Some pages don't have a Controls collection at all. Maybe that's the
problem. If a page uses <% ... %> code blocks mixed with HTML (the old ASP
style) then the whole page ends up as a bunch of Response.Write statements
instead of having a Controls collection with LiteralControl objects
interleaved with other ASP.NET controls.