explorer.exe /idlist,-2109848072,C:\internet
Turning the -nnn back into hex gives us:
0x823E45F8
which looks remarkable like an address in the global memory area!
While I haven't tried it, it seems possible to allocate a pidl in some
global memory, and pass the pointer to it as a cmd line parameter.
I don't think this is really an answer to your question, but it seemed fun
anyway, and it might help a bit :)
jmc...@ix.netcom.com wrote in article
<504quo$7...@sjx-ixn3.ix.netcom.com>...
Hmmm, if anyone does actually try this and succeed I'd be real interested
in hearing from you. :)
Chris
--
chr...@vironix.co.za (Chris Becke)
http://www.vironix.co.za/chrisb
Vironix Software Laboratories
#include <windows.h>
#include <shellapi.h>
#include <stdio.h>
#include <shlobj.h>
LPMALLOC g_pMalloc;
int __cdecl main(int argc, char **argv) {
if (SUCCEEDED(SHGetMalloc(&g_pMalloc))) {
LPITEMIDLIST pidl;
if (SUCCEEDED(SHGetSpecialFolderLocation(0, CSIDL_DRIVES, &pidl))) {
SHELLEXECUTEINFO sei = { sizeof(sei) };
sei.fMask = SEE_MASK_IDLIST;
sei.lpVerb = "open"; // or "explore"
sei.nShow = SW_NORMAL;
sei.lpIDList = pidl;
ShellExecuteEx(&sei);
g_pMalloc->lpVtbl->Free(g_pMalloc, pidl);
}
g_pMalloc->lpVtbl->Release(g_pMalloc);
g_pMalloc = 0;
}
return 0;
}
--
(Note that my return address is intentionally invalid in order
to foil electronic mailing list generation software.)