Existing files displayed despite being deleted

2 posts, 0 answers
  1. Richard
    Richard avatar
    11 posts
    Member since:
    Jul 2010

    Posted 07 Jul 2015 Link to this post

    Hello everyone

    Hopefully I am being stupid but I have the following problem with the rad file explorer. I've set it so a user can upload and delete files. If Istart with a blank cancas, i.e. nothing present in any existing folders and add/delete files, absolutely no problem at all (see Working.gif)

    However, if I already have an existing file present in my file path, I experience a bit of nasty stuff (see NotWorking.gif) - as you can see, the file appears to be present, it isn't, it has been removed from the filepath as requested hence you see the 'resource not found' error when I attempt to open it.

    Here is the code I have.



    <%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Default.aspx.cs" Inherits="Default" %>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <head runat="server">
        <telerik:RadStyleSheetManager ID="RadStyleSheetManager1" runat="server" />
        <form id="form1" runat="server">
            <telerik:RadScriptManager ID="RadScriptManager1" runat="server">
                    <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.Core.js" />
                    <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQuery.js" />
                    <asp:ScriptReference Assembly="Telerik.Web.UI" Name="Telerik.Web.UI.Common.jQueryInclude.js" />
            <script type="text/javascript">
                (function (global, undefined) {
                    function OnClientFileOpen(oExplorer, args) {
                        var item = args.get_item();
                        var fileExtension = item.get_extension();
                        var fileDownloadMode = true;
                        if ((fileDownloadMode == true) && (fileExtension == "txt" || fileExtension == "xls" || fileExtension == "xlsx")) {// Download the file
                            // File is a image document, do not open a new window
                            // Tell browser to open file directly
                            var requestImage = "Handler.ashx?path=" + item.get_url();
                            document.location = requestImage;
                global.OnClientFileOpen = OnClientFileOpen;
            <telerik:RadAjaxManager ID="RadAjaxManager1" runat="server">
                    <telerik:AjaxSetting AjaxControlID="Configuratorpanel1">
                            <telerik:AjaxUpdatedControl ControlID="RadFileExplorer1" LoadingPanelID="theLoadingPanel" />
                <telerik:RadFileExplorer runat="server" ID="RadFileExplorer1" Width="595px" Height="320px"
                    OnClientFileOpen="OnClientFileOpen" EnableOpenFile="true">
                    <Configuration MaxUploadFileSize="51200000"></Configuration>



    using System;
    using System.Web;
    using System.Web.UI;
    using System.Web.UI.WebControls;
    using System.Data;
    using System.Configuration;
    using System.Web.Security;
    using System.Web.UI.WebControls.WebParts;
    using System.Web.UI.HtmlControls;
    using Telerik.Web.UI;
    public partial class Default : System.Web.UI.Page
        protected void Page_Load(object sender, EventArgs e)
            //set properties according to configuration panel
            RadFileExplorer1.Configuration.SearchPatterns = new string[] { "*.jpg", "*.jpeg", "*.gif", "*.png", "*.txt", "*.xls", "*.xlsx" };
            RadFileExplorer1.VisibleControls = GetVisibleControls();
            //Set initial folder to open. Note that the path is case sensitive!
            //var filePath = "~/TestData";
            var filePath = "~/TestData/6645dc9a-5e8c-46e9-aad0-ba9b087aae4a";
            //var filePath = "~/TestData/a4089fd8-3170-4956-a8f5-1ea21a19d984";
            RadFileExplorer1.Configuration.UploadPaths = new string[] { filePath };
            RadFileExplorer1.Configuration.ViewPaths = new string[] { filePath };
            RadFileExplorer1.Configuration.DeletePaths = new string[] { filePath };
            if (!IsPostBack)
                //Set initial folder to open. Note that the path is case sensitive!
                RadFileExplorer1.InitialPath = Page.ResolveUrl(filePath);
        protected Telerik.Web.UI.FileExplorer.FileExplorerControls GetVisibleControls()
            Telerik.Web.UI.FileExplorer.FileExplorerControls explorerControls = 0;
            explorerControls |= Telerik.Web.UI.FileExplorer.FileExplorerControls.All;
            return explorerControls;

    If anyone can point out what I am doing wrong or what else I may need to implement, I'd be most grateful.



  2. Vessy
    Vessy avatar
    1663 posts

    Posted 09 Jul 2015 Link to this post

    Hi Richard,

    I have already answered your support ticket on the subject, for convenience I am pasting my answer here as well:

    Thank you for reporting this issue to us. We are aware of this reggression behavior and it is already fixed in our latest hot fix, which can be downloaded for testing from your Telerik account. The fix will be officially released in out up-coming service pack (2015 Q2 SP1), scheduled for the end of July.

    Unfortunately I am not able to provide any workaround for the moment. Please, excuse us for the caused inconveniences.

    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 Feedback Portal and vote to affect the priority of the items
Back to Top