That makes sense. ‘fold’ and ‘MACS’ are Mac-exclusive properties. (The others are just macros to the same Mac things.)
Windows deals with FileTypes differently. Mac’s have some native types, but (to Xojo anyway) Windows doesn’t have any. This is one of these things that Xojo doesn’t make xplat for you and shows how Mac-centric Xojo is. You have to accept everything (AcceptFileDrop("???")) and then filter it out on MouseEnter or DropObject.
Thanks for the quick reply. I removed the other filetypes and just have AcceptFileDrop("???") in the window and field .open with no change in the results.
I also tried adding a filetype with “???” and then referencing that, still no change.
I am getting the slash when I drag over either.
Is it worth mentioning that I am remote debugging?
All I can comment on is; I do this, very simply, nothing else:
-Open RS2011r3
-New Project
-In the Window1.Open, I put Me.AcceptFileDrop("???")
-In the Window1.DropObject, I check for FolderItemAvailable, and then I print FolderItem.AbsolutePath in a Label I put on the Window.
-Run, I drop any file on the Window, it displays the path in the Label
I know that isn’t Xojo, but this should work. If it was broken in a production version of Xojo, lots of hell would be breaking loose. This is completely necessary.
I don’t know about Remote Debugging, I don’t trust it, but then again I never tried it. I totally believe in debugging on the exact thing you are testing on, but maybe I’m a ostrich. I don’t see how you can be authoritative to a customer unless you are apples-apples with what he’s trying.
Todd, I am assuming that you are not interested in dropping files themselves, only folders. If that is true, then try adding the following code to the DragEnter event for the window/control/whatever you want to drop the folder on.
if obj.FolderItem.Directory = False then Return True
This should prevent anything but a folder from being dropped. After the drop, what you do with the folder or its contents is up to you.
Thanks for all the help but it looks like a Remote Debugger issue… if I do the same thing from XOJO on Windows it works, but the same code sent over the debugger does not. Will file a bug report.