0

I want to be able to drag and drop files remotely in python.

Since I can't get the destination path after the drag and drop, I'm considering using the file hook to get the location of the temporary file I created after the move.

But I don't know how to implement file hooks in python.

I found a case of a file hook written in c++. Can anyone take the time to translate it into python? https://github.com/Eyre-Turing/file_hook.

mark: I have tried to use watchdog to monitor the moving directory, but I am sorry that watchdog cannot do it.

  • Can you please explain what you mean by "drag and drop files remotely"? Drag from what? And to what? Please be more clear. – musicamante Oct 17 '22 at 10:11
  • If you want to trigger some script or have a folder monitored so that a script can perform the actions then you can use "watchdog" its a python library which does exactly same. Here is a link to the thread have a look at it: https://stackoverflow.com/questions/18599339/watchdog-monitoring-file-for-changes – Shantanu Khond Oct 17 '22 at 10:18
  • I want to implement drag and drop download server files to the local. Since files take a long time to download, I need to know the destination path for the drag and drop. I tried to use watchdog to listen to the target path where the file was moved, but watchdog could not listen for movement events. – user18865976 Oct 18 '22 at 02:47

0 Answers0