Skip Navigation LinksHome / Community & Support / Developer Productivity Tools Forums / ASP.NET AJAX > TreeView > Inheriting from RadTreeView

Not answered Inheriting from RadTreeView

Feed from this thread
  • xrimson avatar

    Posted on Feb 6, 2012 (permalink)

    Are there any examples out there on how to inherit from RadTreeView?  I want override both the server side component AND the client side AJAX component.

    I can easily override the server side component, but the problem being that both RadTreeView & MyTreeView has their own AJAX component and I am running into problems when radTreeView fires onCollapsed, the variables initialized in MyTreeView AJAX component are null.

    So I really would like to have myTreeView AJAX component inherit from the RadTreeView AJAX component.  After inheriting from RadTreeVIew is there a way to turn off the AJAX component and just use the inherited one from MyTreeView?

    Reply

  • Simon Simon admin's avatar

    Posted on Feb 13, 2012 (permalink)

    Hi xrimson,

    You can disable all scripts of a RadControl for ASP.NET AJAX by setting its EnableEmbeddedScripts property to false and use your custom JavaScript code, however it is advisable that you do not do this because you will have to implement from scratch every functionality you need.

    It's easier to build on top of RadTreeView's client-side component in your inherited TreeView. You can register the additional JavaScript files with the ClientScriptResourceAttribute (type-level) in this way:
    [ClientScriptResource("AssemblyName", "ScriptResourcePath.js")]

    I hope this helps.

    Kind regards,
    Simon
    the Telerik team
    Sharpen your .NET Ninja skills! Attend Q1 webinar week and get a chance to win a license! Book your seat now >>

    Reply

Back to Top

Skip Navigation LinksHome / Community & Support / Developer Productivity Tools Forums / ASP.NET AJAX > TreeView > Inheriting from RadTreeView
Related resources for "Inheriting from RadTreeView"

ASP.NET TreeView Features  |   Documentation   |  Demos  |  Telerik TV  |  Self-Paced Trainer  |  Step-by-step Tutorial  ]