FileExplorer Bug?

2 posts, 1 answers
  1. Adriana Stamat
    Adriana Stamat avatar
    2 posts
    Member since:
    Oct 2009

    Posted 16 Feb 2010 Link to this post

    Hello, I have the latest FileExplorer version (trial).
    I want to use a simple FileSystem explorer.
    If I set the InitialPath, ViewPaths, UploadPaths, DeletePaths in code (c#), like this



    path = "~/Fisiere/";


    RadFileExplorer1.Configuration.ContentProviderTypeName =




    RadFileExplorer1.InitialPath = path;

    RadFileExplorer1.Configuration.ViewPaths =

    new string[] { path };



    RadFileExplorer1.Configuration.UploadPaths =

    new string[] { path };



    RadFileExplorer1.Configuration.DeletePaths =

    new string[] { path };



    RadFileExplorer1.EnableOpenFile =




    RadFileExplorer1.EnableCopy =




    RadFileExplorer1.DisplayUpFolderItem =




    RadFileExplorer1.AllowPaging =




    RadFileExplorer1.EnableCreateNewFolder =

    it doesn't work (I can't upload, delete, create folder)

    but if I set these properties like this:




    <telerik:RadFileExplorer ID="RadFileExplorer1" Runat="server">



    <Configuration ViewPaths="~/Fisiere/" UploadPaths="~/Fisiere/"




     DeletePaths="~/Fisiere/" /> </telerik:RadFileExplorer>




    it works. I want to be able to set these properties in code (read from web.config)
    Thank you.


  2. Answer
    Fiko avatar
    1406 posts

    Posted 19 Feb 2010 Link to this post

    Hello Adriana,

    We are aware of such a behavior in the current official release (2009.3 1314) and we already fixed it in the 2010 Q1 (still BETA) version of the control. The problem is caused by the fact that the InitialPath is set before setting the ViewPaths, DeletePaths and UploadPaths properties. The problem can be easily avoided by setting the InitialPath property later in the code as shown bellow:
    protected void Page_Load(object sender, EventArgs e)
        string path = "~/Root/";
        RadFileExplorer1.Configuration.ContentProviderTypeName = typeof(FileSystemContentProvider).AssemblyQualifiedName;
      // Original code: RadFileExplorer1.InitialPath = path;
        RadFileExplorer1.Configuration.ViewPaths = new string[] { path };
        RadFileExplorer1.Configuration.UploadPaths = new string[] { path };
        RadFileExplorer1.Configuration.DeletePaths = new string[] { path };
      // Moved here:
        RadFileExplorer1.InitialPath = path;

    I hope this helps.

    All the best,
    the Telerik team

    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items.
Back to Top