How to Implement Custom Verbs for Folders through Desktop.ini
In Windows 7 and later, you can add verbs to a folder by using Desktop.ini. For more information about Desktop.ini files, see How to Customize Folders with Desktop.ini.
To add custom verbs for folders through a Desktop.ini file, perform the following steps.
Create a folder that is marked Read-only or System.
Create a Desktop.ini file that includes a [.ShellClassInfo] DirectoryClass=Folder ProgID.
In the registry, create HKEY_CLASSES_ROOT\Folder ProgID with a value of CanUseForDirectory. The CanUseForDirectory value avoids the misuse of ProgIDs that are set not to participate in implementing custom verbs for folders through Desktop.ini.
Add verbs under the Folder ProgID subkey, for example:
HKEY_CLASSES_ROOT CustomFolderType Shell MyVerb command (Default) = %SystemRoot%\system32\notepad.exe %1\desktop.ini