Cascading Menu and File Explorer Jump Lists Issue in Windows 10

When you implement Cascading Menus in File Folders (Directory) using the SubCommands or ExtendedSubCommands registry keys in Windows 10, an interesting thing happens. The last item in your Cascading menu gets executed when you right-click Pinned File Explorer shortcut in the Taskbar, and click on a folder in the Jump List, instead of a folder window opening.

(This bug was first reported at Microsoft Answers forum, and you can see my response there. As it was later reported by two other users, I decided to write a blog post on this.)

Sample REG file to Reproduce the Issue

Copy the following contents to Notepad, save as "mymenu.reg", and run it.

Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\directory\shell\CustomMenu] "Icon"="shell32.dll,39" "MUIVerb"="MyMenu" "SubCommands"="" [HKEY_CLASSES_ROOT\directory\shell\CustomMenu\shell\menu1] "Icon"="c:\\windows\\system32\\cmd.exe,0" @="Command Prompt" [HKEY_CLASSES_ROOT\directory\shell\CustomMenu\shell\menu1\command] @="cmd.exe \"%1\"" [HKEY_CLASSES_ROOT\directory\shell\CustomMenu\shell\menu2] "Icon"="c:\\windows\\system32\\cmd.exe,0" @="Run Maintenance (Batch File)" [HKEY_CLASSES_ROOT\directory\shell\CustomMenu\shell\menu2\command] @="D:\\Tools\\maintenance.bat"

The cascading menu will show up and work perfectly fine when you right-click a file folder.

Bug: The problem occurs when you right-click on the File Explorer Pinned item in the Taskbar and click on a folder in the Jumplist. Instead of opening a folder window, the last command in your Cascading menu (in this example, "Run Maintenance") gets executed. This is a bug!

Workaround #1

Implementing the Cascading menu under "Folders" or "AllFileSystemObjects" registry key should not cause this problem. However, when implemented in Folders or AllFileSystemObjects registry area, the menu would show up for virtual folders like This PC, Recycle Bin etc as well as for Compressed Folders and files. To prevent it from appearing for files, virtual folders and Compressed (zipped) folders, add a check by creating the AppliesTo REG_SZ value in your Cascading menu.



Set AppliesTo value data to:

kind:file folder AND System.FileExtension:<>".zip"

Revised Registry Settings

Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\Folder\shell\CustomMenu] "Icon"="shell32.dll,39" "MUIVerb"="MyMenu" "SubCommands"="" "AppliesTo"="kind:file folder AND System.FileExtension:<>\".zip\"" [HKEY_CLASSES_ROOT\Folder\shell\CustomMenu\shell\menu1] "Icon"="c:\\windows\\system32\\cmd.exe,0" @="Command Prompt" [HKEY_CLASSES_ROOT\Folder\shell\CustomMenu\shell\menu1\command] @="cmd.exe \"%1\"" [HKEY_CLASSES_ROOT\Folder\shell\CustomMenu\shell\menu2] "Icon"="c:\\windows\\system32\\cmd.exe,0" @="Run Maintenance (Batch File)" [HKEY_CLASSES_ROOT\Folder\shell\CustomMenu\shell\menu2\command] @="D:\\Tools\\maintenance.bat"

Workaround #2

In the Sample REG file at the top of the article, include a 3rd menu command which launches Explorer %1.

[HKEY_CLASSES_ROOT\directory\shell\CustomMenu\shell\menu3\command]
@="explorer.exe \"%1\""

But it will always show up in your Cascading menu.. When you select a folder in the Jumplist, this item (last in the menu) is executed.


One small request: If you liked this post, please share this?

One "tiny" share from you would seriously help a lot with the growth of this blog. Some great suggestions:
  • Pin it!
  • Share it to your favorite blog + Facebook, Reddit
  • Tweet it!
So thank you so much for your support. It won't take more than 10 seconds of your time. The share buttons are right below. :)

Ramesh Srinivasan is passionate about Microsoft technologies and he has been a consecutive ten-time recipient of the Microsoft Most Valuable Professional award in the Windows Shell/Desktop Experience category, from 2003 to 2012. He loves to troubleshoot and write about Windows. Ramesh founded Winhelponline.com in 2005.

Leave a Comment