Cause FileExplorer to populate node from server side

6 posts, 0 answers
  1. Robert Colbert
    Robert Colbert avatar
    3 posts
    Member since:
    Sep 2009

    Posted 03 Oct 2011 Link to this post

    I am trying to store/retrieve a list of selected items in a file explorer control. I have been able to retrieve the checked nodes and store them without any difficulty but I am running in to a problem when I try to load the list of items back in the the explorer if they reside in nodes that have not been loaded.

    Is it possible to trigger the FileExplorer control to pre-load/expand a node path from the server api?
  2. Dobromir
    Admin
    Dobromir avatar
    1633 posts

    Posted 04 Oct 2011 Link to this post

    Hi Robert,

    In order to pre-load a specific sub-folder, you need to set RadFileExplorer's InitialPath property to point to that sub-folder. Please review the following live demo for an example:
    FileExplorer / InitialPath and Paging

    All the best,
    Dobromir
    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
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Robert Colbert
    Robert Colbert avatar
    3 posts
    Member since:
    Sep 2009

    Posted 07 Oct 2011 Link to this post

    The server-side loading would be after the root of the tree had loaded and branches to load might contain multiple entries in different sections of the tree.

    ex:

    Items to select in FileExplorer:
    /branch1/subfolder1/
    /branch3/subfolder2/subfolder3/

    The root of the tree contains:
    /branch1
    /branch2
    /branch3
    /branch4

    Can InitialPath be used in the case where I need to pre-load multiple paths?
  5. Dobromir
    Admin
    Dobromir avatar
    1633 posts

    Posted 10 Oct 2011 Link to this post

    Hi Robert,

    In short, no, the InitialPath cannot be used to pre-load multiple folders.

    On a side note, I am not quite sure I understand what you are trying to achieve, could you please describe in more details the specific scenario?

    Best wishes,
    Dobromir
    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
  6. Robert Colbert
    Robert Colbert avatar
    3 posts
    Member since:
    Sep 2009

    Posted 17 Oct 2011 Link to this post

    The specific scenario is this:

    I wrote my own content provider to interact with SharePoint 2010 using the client object model. The explorer is being used to select a list of objects to be used when migrating SharePoint content between server farms with the ability to save the list of selected objects for re-use.

    Iterating through the list and selecting the objects works properly as does taking that list and persisting it to a database. I run in to issues trying to load the list back from the database on a fresh load of the FileExplorer. If I had already expanded all paths in FileExplorer before trying to load the selected item list, it works fine. Otherwise FileExplorer only selects the items that were checked at the top level of the list.
  7. Dobromir
    Admin
    Dobromir avatar
    1633 posts

    Posted 19 Oct 2011 Link to this post

    Hi Robert,

    Thank you for the provided detail information.

    For this scenario I would suggest you to store selected items in a container on the page (a hidden field, a javascript variable, etc) and handle the RadFileExplorer's ClientFolderChange client-side event and select the file(s) that exist in the container.

    Greetings,
    Dobromir
    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
UI for ASP.NET Ajax is Ready for VS 2017