Unplanned
Last Updated: 25 Dec 2020 11:05 by ADMIN
Jake
Created on: 25 Dec 2020 11:00
Category: FileManager
Type: Bug Report
0
FileManager navigate method throws an error when navigating to a subfolder
So my filemanager on page load, loads the root directory.  I I wish to call the method navigate(folderpath) for a subfolder (https://docs.telerik.com/kendo-ui/api/javascript/ui/filemanager/events/navigate) but it does not work because I haven't loaded that subfolder yet using the normal navigation methods provided directly by the filemanager.  The navigate call does not call read on the datasource the same as clicking on a folder does in filemanager.  Hence I get the error cannot get loaded property of undefined or null ref.
1 comment
ADMIN
Misho
Posted on: 25 Dec 2020 11:05

Hello,

  

I was able to replicate the undesired behavior you are experiencing with navigating to a subfolder by using the navigate method. I've created a sample project containing a Folder and a subfolder structure. Then on button click I use the navigate method to open the subfolder and observed the "Uncaught TypeError: Cannot read property 'loaded' of undefined" error occur.

I've logged this as a bug in our public Github repo for further research

https://github.com/telerik/kendo-ui-core/issues/6207

You could observe its status also from our public feedback portal where other users could also vote for raising its priority:
https://feedback.telerik.com/kendo-jquery-ui/1500317-filemanager-navigate-method-throws-an-error-when-navigating-to-a-subfolder


The error is not thrown if separating the navigation and calling the navigation to a subfolder in a timeout:

var fileManager = $("#filemanager").data("kendoFileManager");
            fileManager.navigate("Images");
            setTimeout(function () { fileManager.navigate("Images/NestedFolder"); }, 200);

 

Best Regards,
Misho
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.