// Top of ur .cs file ... using AndroidCtrl; using AndroidCtrlUI.Explorer; using AndroidCtrlUI.Explorer.Actions.Windows; ... // OnDrop handler public void OnDrop(object sender, DragEventArgs e) { // Drop destination path string dest = "C:\\"; // Here we check if the drop element includes a DataObject if (e.Data is DataObject d && d.ContainsFileDropList()) { // Extract the sender string s = d.GetText(TextDataFormat.Text); // Check if the sender is the android viewmodel. if (s == "android" && d.GetDataPresent(typeof(DeviceInfo))) { // Now init the copy process Copy copy = new Copy(this, (DeviceInfo)d.GetData(typeof(DeviceInfo)), s, "local", dest, d.GetFileDropList(), e.Effects == DragDropEffects.Move); // (optional) Here you can define a callback which is raised if the copy window is closed. copy.Closed += DropCallback; // Show the copy window copy.Show(); } // If the sender isn't the android viewmodel, your OnDrop code will be executed. else { // Your OnDrop code goes here. } } e.Handled = true; } // (optional) Callback after the window is closed. private void DropCallback(object sender, EventArgs e) { // Do a refresh or something. }
Here i'll show you how to implement the Drag & Drop in your program code.