Ok, there is only one mechanism that you will have to change (the visible part). That is to have another property called "RenderToClient". And you will have to control the rendering a bit. So your code should look something like this:
private bool pRenderToClient = false;
public bool RenderToClient {
get { return pRenderToClient; }
set { pRenderToClient = value; }
}
protected override void Render(HtmlTextWriter writer) {
if (RenderToClient)
base.Render(writer);
}
-- Justin Lovell