Hide ViewPath

4 posts, 0 answers
  1. Jane
    Jane avatar
    12 posts
    Member since:
    Jun 2014

    Posted 03 Jun 2014 Link to this post

    Is there any way to not display the ViewPath location to the user but still allow them to upload?  I tried to not define the property, but that also disabled the Upload button.
  2. Vessy
    Admin
    Vessy avatar
    1382 posts

    Posted 06 Jun 2014 Link to this post

    Hello Jane,

    I am not sure whether I understand the exact issue correctly. The product in the ticket is marked as ImageEditor, but I assume you might be using the Editor's ImageManager or FileExplorer. Am I correct or are you using an ImageEditor integrated with an AsyncUpload control (refer this demo)?

    It would be really helpful if you provide a screenshot explaining the exact element you would like to hide so I could help you further.

    Looking forward to hearing from you,
    Vessy
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
  3. UI for ASP.NET Ajax is Ready for VS 2017
  4. Jane
    Jane avatar
    12 posts
    Member since:
    Jun 2014

    Posted 06 Jun 2014 in reply to Vessy Link to this post

    Sorry, you are correct I am talking about the image manager.  I would not like the users to see the other files that have already been uploaded, I'd like either a blank screen or the users computer.  However, I still need the users to be able to upload files.  See attached file.
  5. Vessy
    Admin
    Vessy avatar
    1382 posts

    Posted 10 Jun 2014 Link to this post

    Hi Jane,

    I am afraid that FileExplorer (the control used for listing files and folders in the Editor's ImageManager) cannot function without having configured ViewPaths. What you can do is to create a separate folder for each user, so he would be able to see only the files he has uploaded. For example:
    protected void Page_Load(object sender, EventArgs e)
    {
        string userId = "1234"; //your logic for accessing the ID of the current user here
        string[] viewpaths = new string[] { String.Format("~/ROOT/{0}", userId)};
        RadEditor1.ImageManager.ViewPaths = viewpaths;
        RadEditor1.ImageManager.UploadPaths = viewpaths;
        RadEditor1.ImageManager.DeletePaths = viewpaths;
    }

    Furthermore, you can hide the FileExplorer's AddressBox so the user will not see the path to the configured by you root folder. In order to do it, you will need to enable the external dialogs of the Editor and modify the FileExplorer's configuration in the FileBrowser.ascx file in a similar way:
    <div class="redFEWrapper">
        <telerik:RadFileExplorer ID="RadFileExplorer1" Height="400px" Width="400px" TreePaneWidth="150px" runat="Server" EnableOpenFile="false" AllowPaging="true" PageSize="100"
            VisibleControls="ContextMenus,FileList,Grid,ListView,Toolbar,TreeView">
        </telerik:RadFileExplorer>
    </div>

    Hope this helps.

    Regards,
    Vessy
    Telerik
     

    Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

     
Back to Top