This is a migrated thread and some comments may be shown as answers.

Folder rename issue in the treeview

4 Answers 177 Views
FileExplorer
This is a migrated thread and some comments may be shown as answers.
John
Top achievements
Rank 1
John asked on 08 Sep 2016, 12:54 PM

Hi Team,

 

When I try renaming a folder in treeview pane, I am getting following error:

Stack Trace:
  at System.String.Substring(Int32 startIndex, Int32 length)
  at Telerik.Web.UI.RadFileExplorer.RenameTreeNode(RadTreeNode node, String newName)
  at Telerik.Web.UI.RadFileExplorer.RadTreeView1_NodeEdit(Object sender, RadTreeNodeEditEventArgs e)
  at Telerik.Web.UI.RadTreeView.OnNodeEdit(RadTreeNodeEditEventArgs e)
  at Telerik.Web.UI.RadTreeView.RaisePostBackEvent(String eventArgument)
  at Telerik.Web.UI.RadTreeView.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument)
  at System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument)
  at System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData)
  at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)

 

 

However, file rename operation works fine. Can you please investigate the issue?

 

4 Answers, 1 is accepted

Sort by
0
Vessy
Telerik team
answered on 08 Sep 2016, 02:33 PM
Hi John,

Are you, by any chance, updating RadFileExplorer externally via AJAX requests? Can you disable the AJAX on the page and see whether the problem persists?

If this is not the case, can you send us the exact configuration needed for reproducing the case so we can examine the problematic behavior at out end?

Looking forward to your reply,
Vessy
Telerik by Progress
Do you need help with upgrading your ASP.NET AJAX, WPF or WinForms projects? Check the Telerik API Analyzer and share your thoughts.
0
John
Top achievements
Rank 1
answered on 09 Sep 2016, 08:21 AM

Hi Vessy,

 

There are no external ajax requests.

I am using a Custom content provider. Rest all the operations are working fine (even renaming of files).

 

It seems exactly the same issue was faced by another user few years ago:

http://www.telerik.com/forums/rename-a-directory

0
John
Top achievements
Rank 1
answered on 09 Sep 2016, 09:42 AM

Error disappears if folder path ends with a forward slash. However, I now have to make changes in custom content provider code accordingly to handle this.

 

Can you please explain why there is a dependency on having a forward slash at the end of folder path?

0
Vessy
Telerik team
answered on 14 Sep 2016, 10:45 AM
Hi John,

The described behavior depends on the custom content provider implementation and the behvaior of FileExplorer depends on it. Can you elaborate a bit on which content provider you are using? Is it any of the implemented by us ones or is it implemented by you?

I tested the folder renaming in the following live demo using the provided by us DB content provider, but was able to rename the folders without adding end slash to the folder name. Are you reproducing the same problem with it?
http://demos.telerik.com/aspnet-ajax/fileexplorer/examples/server-sideapi/dbfilebrowsercontentprovider/defaultcs.aspx


Regards,
Vessy
Telerik by Progress
Do you need help with upgrading your ASP.NET AJAX, WPF or WinForms projects? Check the Telerik API Analyzer and share your thoughts.
Tags
FileExplorer
Asked by
John
Top achievements
Rank 1
Answers by
Vessy
Telerik team
John
Top achievements
Rank 1
Share this question
or