in reply to Re: Re: Windows drag and drop (boo)
in thread Windows drag and drop

And on that very page they say: Drop handlers are registered under the file class's HKEY_CLASSES_ROOT\ProgID\Shellex\DropHandler subkey. Create a subkey of DropHandler named for the handler, and set the subkey's default value to the string form of the handler's CLSID GUID.
(emphasis mine)
What handles .pl files? Is it perl.dll or is it shell.dll(shell.dll being the handler for executables)? Does your system have a registered CLSID for perl56.dll?
More importantly, what happens when shell.dll gets an DDE request it may not understand or be able to handle?

Replies are listed 'Best First'.
Re: Son of Windows drag and drop (boo)
by osfameron (Hermit) on Oct 31, 2001 at 04:55 UTC

    Phew: I knew I should have studied my NT harder... some good questions, and I've already said in orig. node that I don't recommend trying this

    On the other hand I think that the instructions above are correct. I don't think that the shell extension is doing anything in particular with Perl - but I may have misunderstood the question.

    I think the process is

    • When the user tries to drop an input file onto a .pl script, NT checks the registry and see .pl => perl
    • It then checks HKEY_CLASSES_ROOT\perl\Shellex\DropHandler to see if it has a registered drophandler.
    • If the drophandler exists, it is run. Presumably it is passed the details of a) the dropped input file and b) the perl script
    • As the handler shell32.dll on my system seems to deal with .bat, .com, .pif, .scr and other files that existed from way before OLE, I think that all it does is the equivalent of the command line  "%1" "%2" e.g. runs the exe with the parameter of the dropped file.
    • (Which would explain why it worked - for me - for Perl.) The perl dll's aren't having to be registered to do any playing with shell extensions. It's just Shell32.dll spawning a new process similar to what it does on the command line.

    That's my guess anyway!

    Cheerio!
    Osfameron