Drag'n'drop from app to desktop/explorer
Hello everyone.
I have a drag'n'drop problem, i want to drag files from my encrypted archive and drop onto the desktop or explorer.
The problem is that the files does not exist at the drop moment, they need to be extracted first. How do i intercept the drop path or making Windows wait until my files has been extracted before copying them to the drop path?
I can't use any of the earlier OLE events such as OLESetData to extract the files, the drop operation is not completed by then and i have no way of telling if the user was going to fulfill or cancel it. It looks bad too if the program is starting to extract a really large file in the middle of a drag operation.
Thank you in advance!
KE
Re: Drag'n'drop from app to desktop/explorer
I managed to figure this out by myself.
You have to check the state of the mouse button with the GetKeyState API when the OLESetdata event fires and exit the sub if the return value is other than 0.
If it returns 0 then i can process my files in the OLESetdata event and then fill the data object with file names.
Works perfectly.