Rendering Tree View

1 posts, 0 answers
  1. Ken
    Ken avatar
    6 posts
    Member since:
    Jul 2008

    Posted 11 Feb 2009 Link to this post

    I have a RadTreeView that I would like to render the html for so that I can put it in an email.  When I try to call the tree's RenderControl Method I get an error:

    Script control 'TOCTree' is not a registered script control. Script controls must be registered using RegisterScriptControl() before calling RegisterScriptDescriptors().
    Parameter name: scriptControl

    Here is the code.


    protected void btnEmail_Click(object sender, EventArgs e)




        StringBuilder sb = new StringBuilder();



        StringWriter sw = new StringWriter(sb);



        HtmlTextWriter tw = new HtmlTextWriter(sw);






        //render the table of contents tree
        TOCTree.RenderControl(tw); //error on this line



    I've tried a lot of things but I can't seem to get rid of this error.  Please help.

Back to Top