Hi,
Just wondering if it is possible to make a folder association on
windows xp/vista
Basically I have a folder with alot of things in it and I want my users
to just double click on that folder then it will launch my application
and have my application to go through the contents inside that folder. I
know how to do a file assoication but I really want to implement folder
association.
the reason behind this is because I want my application to produce
these custom folders (many of these "packages") and when my users double
click on these "packages" instead of openning it as a folder, it will
launch my application and go through these "packages", is kind of like a
portable thing..
I have been experimenting with things, the code below sort out some of
my problems, but not exactly what I want...
if I rename a Vista folder and add the extension of the CLSID i.e.
MyCustomFolder.{30a7e1b3-e763-4789-a54d-fcc53dcf973a}]
(Please Refer to the code below)
it will create MyCustomfolder, but it does not give open my application
via double click
Code:
--------------------
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\CLSID\{30a7e1b3-e763-4789-a54d-fcc53dcf973a}]
@="MyCustomFolder"
[HKEY_CLASSES_ROOT\CLSID\{30a7e1b3-e763-4789-a54d-fcc53dcf973a}\DefaultIcon]
@="C:\\Users\\Simon\\Desktop\\icon\\mycustomicon.i co"
[HKEY_CLASSES_ROOT\CLSID\{30a7e1b3-e763-4789-a54d-fcc53dcf973a}\InProcServer32]
@="shell32.dll"
"ThreadingModel"="Apartment"
[HKEY_CLASSES_ROOT\CLSID\{30a7e1b3-e763-4789-a54d-fcc53dcf973a}\Shell]
[HKEY_CLASSES_ROOT\CLSID\{30a7e1b3-e763-4789-a54d-fcc53dcf973a}\Shell\Open MyCustomFolder]
[HKEY_CLASSES_ROOT\CLSID\{30a7e1b3-e763-4789-a54d-fcc53dcf973a}\Shell\Open MyCustomFolder\Command]
@="C:\\Program Files\\MyApplication.exe"
[HKEY_CLASSES_ROOT\CLSID\{30a7e1b3-e763-4789-a54d-fcc53dcf973a}\ShellEx]
[HKEY_CLASSES_ROOT\CLSID\{30a7e1b3-e763-4789-a54d-fcc53dcf973a}\ShellEx\PropertySheetHandlers]
[HKEY_CLASSES_ROOT\CLSID\{30a7e1b3-e763-4789-a54d-fcc53dcf973a}\ShellEx\PropertySheetHandlers\{30a7e 1b3-e763-4789-a54d-fcc53dcf973a}]
[HKEY_CLASSES_ROOT\CLSID\{30a7e1b3-e763-4789-a54d-fcc53dcf973a}\ShellFolder]
"Attributes"=hex:00,00,00,00
--------------------
Can someone kindly shed some light?
Thank you so much
Simon
--
extraz
Posted via
http://www.vistaheads.com