We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

How to refresh Tree or Remove/Change Current Folder Selection

Thread ID:





129410 Mar 16,2017 10:07 AM UTC Mar 17,2017 04:10 PM UTC JavaScript 1
Tags: ejFileExplorer
Asked On March 16, 2017 10:20 AM UTC

i have work on java script api file explorer in asp.net mvc when i select folder and it containing single file when i have remove file and folder from c# code 
and refresh file explorer using fileExplorerObj.refresh(); method it gives an error message System.IO.DirectoryNotFoundException.

i want refresh the tree and display only available folder in the root directory

as well as change selection of folder from jquery

please revert back asap.

Ashokkumar Balasubramanian [Syncfusion]
Replied On March 17, 2017 04:10 PM UTC

Hi Sagar, 
We have analyzed your query (“How to refresh Tree or Remove/Change Current Folder Selection”). We suspect that, the reported issue occurs due to handle the deletion and refresh operions in same Folder Location. So please use the below code snippet to resolve this issue. 
            url: '@Url.Action("Remove", "FileExplorer")', 
            type: "POST", 
            dataType: "json", 
            data: { Name: value, path: args.path }, 
            success: function (data) { 
                var fileObj = $("#fileexplorer").ejFileExplorer("instance"); 
                fileObj.option("selectedFolder", data); //Pass the parent folder 
For your requirement, we have prepared simple sample, it can be downloaded in below location. 
Please let us know, if you have any other concerns, 
Ashokkumar B. 


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.