D
Deane
I am rendering a user control manually using "LoadControl" and
"RenderControl" to get the results of the control (the HTML) back as a
string. The control is never added to the Page's Controls collection.
This is causing all kinds of problems with child controls of the
control I'm rendering manually. Those child controls may have code in
their Page_Load events (which doesn't fire), and -- additionally --
the RenderControl method doesn't seem to cause child controls to
render themselves.
I need to be able to execute a control in a "sandbox," so to speak. I
need an execution space that will render all child controls, fire all
events, etc. just as if the control was in Page's Controls
collection. But I need to get the resulting HTML back as a string.
How possible is this?
"RenderControl" to get the results of the control (the HTML) back as a
string. The control is never added to the Page's Controls collection.
This is causing all kinds of problems with child controls of the
control I'm rendering manually. Those child controls may have code in
their Page_Load events (which doesn't fire), and -- additionally --
the RenderControl method doesn't seem to cause child controls to
render themselves.
I need to be able to execute a control in a "sandbox," so to speak. I
need an execution space that will render all child controls, fire all
events, etc. just as if the control was in Page's Controls
collection. But I need to get the resulting HTML back as a string.
How possible is this?