Customize a folder name in RadFileExplorer

2 posts, 1 answers
  1. ABC
    ABC avatar
    20 posts
    Member since:
    Mar 2012

    Posted 12 Sep 2013 Link to this post

    I have specific folder names for each users, like, 1, 2, 3, 4, etc. I need to make this My Documents. Is it possible to just change it's directory name?
  2. Answer
    Ianko avatar
    1738 posts

    Posted 17 Sep 2013 Link to this post


    You could use a custom content provider and modify the ResolveRootDirectoryAsTree() method with the desired functionality to change the folder's name.

    Please follow this server-side implementation as an example for the desired customization:
    public class CustomContentProvider : FileSystemContentProvider
        public CustomContentProvider(HttpContext context, string[] searchPatterns, string[] viewPaths, string[] uploadPaths, string[] deletePaths, string selectedUrl, string selectedItemTag)
            : base(context, searchPatterns, viewPaths, uploadPaths, deletePaths, selectedUrl, selectedItemTag)
        public override DirectoryItem ResolveRootDirectoryAsTree(string path)
            DirectoryItem orgDir = base.ResolveRootDirectoryAsTree(path);
            if (orgDir.Name.ToLower() == "customfolder")
                orgDir.Name = "ModifiedName";
            return orgDir;

    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 the blog feed now.
Back to Top