win7系統中,用註冊表的方式添加幾個右鍵菜單

1.文件夾裏面 空白處》右鍵菜單》生成文件清單
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\Directory\Background\shell\生成文件清單]
[HKEY_CLASSES_ROOT\Directory\Background\shell\生成文件清單\command]
@="C:\\Windows\\System32\\cmd.exe /c tree /f > 文件清單filelist.txt "

2.選中文件夾後》右鍵菜單》生成文件清單
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\Folder\shell\生成文件清單]
[HKEY_CLASSES_ROOT\Folder\shell\生成文件清單\command]
@="C:\\Windows\\System32\\cmd.exe /c tree \"%1\" /f > \"%1\\文件清單filelist.txt\" "

3.選中文件夾後》右鍵菜單》在此目錄打開cmd
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\Folder\shell\在此目錄打開cmd]
[HKEY_CLASSES_ROOT\Folder\shell\在此目錄打開cmd\command]
@="C:\\Windows\\System32\\cmd.exe /k cd %l"

4. 文件夾裏面 空白處》右鍵菜單》在此目錄打開cmd
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\Directory\Background\shell\在此目錄打開cmd]
[HKEY_CLASSES_ROOT\Directory\Background\shell\在此目錄打開cmd\command] 
@="C:\\Windows\\System32\\cmd.exe /k"

--以下使用了自己開發的java程序,不具備通用性,只有技術參考性---------------------------------
執行命令行調用java程序:選中文件夾後》右鍵菜單》照片整理
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\Folder\shell\照片整理]
[HKEY_CLASSES_ROOT\Folder\shell\照片整理\command]
@="C:\\Windows\\System32\\cmd.exe /k java -classpath \"F:/imgAutoTool/imggrouptool.jar;F:/imgAutoTool/lib/chineseutils-0.1.jar;F:/imgAutoTool/lib/commons-beanutils-1.7.0.jar;F:/imgAutoTool/lib/commons-codec-1.9.jar;F:/imgAutoTool/lib/commons-collections-3.2.1.jar;F:/imgAutoTool/lib/commons-io-2.4.jar;F:/imgAutoTool/lib/commons-lang3-3.3.2.jar;F:/imgAutoTool/lib/metadata-extractor-2.8.1.jar;F:/imgAutoTool/lib/slf4j-api-1.7.5.jar;F:/imgAutoTool/lib/xmpcore-5.1.2.jar;\" test.ImgAutoGroup \"%l\" \"86400000\" \"jpg,mov,nef,cr2,mp4,orf\""

 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章