TreeList - Membership & Roles

3 posts, 0 answers
  1. Franklin
    Franklin avatar
    10 posts
    Member since:
    Jul 2012

    Posted 17 Jul 2012 Link to this post

    How can I restrict the access and the manipulation (add, edit, delete) of a TreeList with my membership provider based on roles?
    Is this posible or how what can I do?
    Thanks in advanced
  2. Franklin
    Franklin avatar
    10 posts
    Member since:
    Jul 2012

    Posted 18 Jul 2012 Link to this post

    Is possible establish permissions for each row, such that one role just can see the row, another can see and edit, and another cannot see it?

    Thanks for your Help.
  3. Andrey
    Andrey avatar
    836 posts

    Posted 20 Jul 2012 Link to this post


    Out of the box such functionality is not available for RadTreeList. In order to achieve your goal you need to manually allow/restrict the user from viewing the information.

    The approach is as follows:

    • You need to hook the ItemDataBound event of RadTreeList
    • In its body you should check what is the currently bound item and then the event argument item to the appropriate type
    • Then based on some condition you should either hide or show the required item.

    You could use the following help topics from RadTreeList documentation:

    Accessing cells and rows
    Edit modes

    Additionally, for the condition you could use the:

    Membership class
    Role class
    FormsAuthentication class

    All the best,
    the Telerik team
    If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Back to Top