ControlAdapter.RenderChildren(HtmlTextWriter) Method

Definition

Generates the target-specific markup for the child controls in a composite control to which the control adapter is attached.

protected:
 virtual void RenderChildren(System::Web::UI::HtmlTextWriter ^ writer);
protected virtual void RenderChildren (System.Web.UI.HtmlTextWriter writer);
abstract member RenderChildren : System.Web.UI.HtmlTextWriter -> unit
override this.RenderChildren : System.Web.UI.HtmlTextWriter -> unit
Protected Overridable Sub RenderChildren (writer As HtmlTextWriter)

Parameters

writer
HtmlTextWriter

The HtmlTextWriter to use to render the target-specific output.

Remarks

Override the RenderChildren method when it is necessary to generate target-specific markup for the child control set of a composite control, in addition to the markup for the individual child controls.

Notes to Inheritors

When you inherit from the ControlAdapter class, for a composite control, the adapter developer must ensure that the child controls are rendered. If the adapter overrides the RenderChildren(HtmlTextWriter) method, it should call the RenderChildren(HtmlTextWriter) method from an override of the Render(HtmlTextWriter) method.

If the Render(HtmlTextWriter) method causes the child controls to be rendered but itself does not generate markup, it might be appropriate for the Render(HtmlTextWriter) method to call its base method, which calls the Render(HtmlTextWriter) method, instead of implementing an override for the RenderChildren(HtmlTextWriter) method.

Applies to

See also