Guess I'm starting to get this hang of this.
To create a custom web container control, inherit from HTML anchor, create a
table, add content to the middle cell, and override the render method.
Protected Overrides Sub Render(ByVal writer As
System.Web.UI.HtmlTextWriter)
CC.Controls.Clear()
Dim cnts(Me.Controls.Count - 1) As System.Web.UI.Control
Me.Controls.CopyTo(cnts, 0)
For Each cnt As System.Web.UI.Control In cnts
CC.Controls.Add(cnt)
Next
tbl.RenderControl(writer)
End Sub
For some reason I can't get the border to render at design-time, but still,
this is more than I expected; design-time drag-drop works!
Paul
"PJ6" <> wrote in message
news:...
>I have a simple container that I want to be able to use at design-time - as
>in, be able to drag a control into it and drop it in. I already went
>through of some problems in WinForms that this kind of functionality
>presents, so I don't exactly need it that nice - I'd be satisfied with just
>manually adding HTML in between the tags of the control. Just can't figure
>out how to get it to render what's inside its tags at the moment.
>
> TIA,
> Paul
>
|