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

RadFileExplorer views are not being disabled and Drag/Drop issues

1 Answer 80 Views
FileExplorer
This is a migrated thread and some comments may be shown as answers.
Sean
Top achievements
Rank 1
Sean asked on 29 Oct 2014, 04:04 AM
I am trying to solve this problem, either:
a) Disable all drag and drop across all parts of the file explorer
or
b) Enable drag and drop inside the grid view, list view, tree view etc

1) As part of my testing and playing around with the file explorer, I tried setting these

            FileExplorer1.FileList.ListView.Enabled = false;
            FileExplorer1.FileList.Grid.Enabled = false;

            FileExplorer1.ListView.Enabled = false;
            FileExplorer1.Grid.Enabled = false;

            FileExplorer1.FileList.ListView.ClientSettings.AllowItemsDragDrop = false;
            FileExplorer1.FileList.Grid.ClientSettings.AllowRowsDragDrop = false;

All of which made no observable change to the control.
These however, did work as expected:
           
            FileExplorer1.TreeView.EnableDragAndDrop = false;
            FileExplorer1.TreeView.Enabled = false;

Why did the other lines have no effect?

2) To disable dragging and dropping for the file explorer, I'm told I can use this:

        explorer.get_fileList().get_grid().add_rowDragStarted(RowDragStarted);

        function RowDragStarted(grid, args) {
            args.set_cancel(true);
        }

Is there an easier way to disable or enable drag/dropping without going through every view for an entire File Explorer?

3) When inside the grid or thumbnail view, dragging a file over another folder does not trigger the move file event, but dragging over to the tree view does. How can I trigger this for the grid/thumbnail event?

Thanks,
Sean

1 Answer, 1 is accepted

Sort by
0
Vessy
Telerik team
answered on 31 Oct 2014, 04:59 PM
Hi Sean,

I am not quite sure whether I understand the difference between a) and b) goals. By design the only dragging supported in FileExplorer is from the Grid/ListView to the TreeView and vice versa. In order to disable it you can follow the instructions from the following forum thread: Disable Drag-Drop not working. Unfortunately there is no an easier way to disable the dragging of the Grid.

Regarding the disabling of the controls - I am afraid that it cannot be achieved. The only thing I can suggest you is to define the FileExplorer's VisibleControls property in order to remain only the needed ones.


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.

 
Tags
FileExplorer
Asked by
Sean
Top achievements
Rank 1
Answers by
Vessy
Telerik team
Share this question
or