asp.net - Custom container control -
i'm trying create collapsiblepanel control, panel has header can used expand / collapse body. i've got example of working on page (inline) make reusable control can used follows
<cc:collapsiblepanel runat="server" header="this collapsible panel"> <asp:label runat="server" text="this contents of panel" /> </cc:collapsiblepanel> so, want collapsiblepanel render header, beginning of container, contents of container (i.e. label in case), , end of container.
i'm unsure how properly. i've seen examples override rendering methods in order insert controls @ right points, seems hack-y.
what 'proper' way this? (.net 4.0 if makes difference)
overriding rendering methods best way this. use renderbegintag , renderendtag.
Comments
Post a Comment