1. The structure
Welcome back with your list of 12 programs. Exciting, isn't it?. Let's make YOUR menu. That will be fun and easy! I am using these general terms throughout this coaching in order for everyone to substitute their own categories and programs.
Layer #1: The Title ➤ (when you right-click on your desktop)
Layer #2: Category 1 ➤ , Category 2 ➤ and Category 3 ➤.
Layer #3 (
opened from Category 1): program 1a, program 1b, program 1c and program 1d.
Layer #3 (
opened from Category 2): program 2a, program 2b, separator and Category 4 ➤
Layer #3 (
opened from Category 3): program 3a, program 3b, program 3c and program 3d.
Layer #4 (
opened via Category 2): program 4a and program 4b.
Note: The maximun of items is 17, which includes the categories, the programs and the separators. Therefore, if you want to add another separator, then you will have to remove a program, vice-versa.
a) Let's write down in a text file the structure of your menu and all the paths of your programs and their icons. Then, once we have verified your syntax and the data, we will copy & paste everything quickly in the registry to avoid any typo and a too long session in it. Save you text file right NOW even if it is empty. Then, Ctrl+S often.
Start by filling the two first columns with your four categories and 12 programs, where the first one is the program's name
Without Space for the keys, and in the second one, the name that you want to see on the menu. We will add the paths later. Example of the first line:
“New_Keys” : ........ “Seen on the menu”..............
TheTitle :: ............ The Title ............................
CascadeMenu :: .... ¯¯¯ Cascade—Menu __(°¿°)...
The template:
Code:
“New_Keys” : ..“Seen on the menu”. “Icon's path” .... “Program's path”
TheTitle :: ... " The Title" ..... _____________
Category1 : ... " Category #1" ... _____________
Program1a : ... " Program #01" ... _____________ ... _________________
Program1b : ... " Program #02" ... _____________ ... _________________
Program1c : ... " Program #03" ... _____________ ... _________________
Program1d : ... " Program #04" ... _____________ ... _________________
Category2 : ... " Category #2" ... _____________
Program2a : ... " Program #05" ... _____________ ... _________________
Program2b : ... " Program #06" ... _____________ ... _________________
Category3 : ... " Category #3" ... _____________
Program3a : ... " Program #07" ... _____________ ... _________________
Program3b : ... " Program #08" ... _____________ ... _________________
Program3c : ... " Program #09" ... _____________ ... _________________
Program3d : ... " Program #10" ... _____________ ... _________________
Category4 : ... " Category #4" ... _____________
Program4a : ... " Program #11" ... _____________ ... _________________
Program4b : ... " Program #12" ... _____________ ... _________________
b) OK. Let's group your keys into Arrays that will have no space. A
semi-colon ‘
; ’ separates each key and each separator that is the
| character.
The Arrays:
Code:
TheTitle = [Category1;Category2;Category3]
Category1 = [Program1a;Program1b;Program1c;Program1d]
Category2 = [Program2a;Program2b;|;Category4]
Category3 = [Program3a;Program3b;Program3c;Program3d]
Category4 = [Program4a;Program4b]
Note: The order of the items on your menu is according to the content of your Arrays. So, if you want the Category 4 to be on top instead and the two programs under the separator, change the Category2's Array from:
Program2a;Program2b;|;Category4
to
Category4;|;Program2a;Program2b
c) Add also these special words on a separated line because they will be copied & pasted many times. If you copy & paste them from here, make sure there are no extra characters at their ends, like ‘\n’ or a space.
The special words:
command
Icon
MUIVerb
SubCommands
Note: See also the template and the Arrays of the photos above in my first comment.
2. The Paths of your Programs and their Icons
The best way to avoid any typo is to copy & paste them from your Windows Explorer.
Tip
To switch quickly from the Explorer to your text file, hold down the ALT key on the left of the space bar while you press the Tab key as many times as you need to select the proper window. Release the TAB key first, then, the switch appends when you release the Alt key. The quickest is to have only two windows opened.
To copy the path of a file, hold down the Shift key and right-click on the file. That adds a few more shortcuts on the context menu. You should find a new one like ‘copy as path’. If your windows version does not provide that feature, install a very useful tool that does it, like ClipboardPath.
The Syntax of the path.
a) The path that has a space in it must be quoted:
"C:\Program Files (x86)\folder\program.exe"
Brief, space = quotes; no_space = no_quote.
b) The Path of the icon:
- must include its index number,
- be separated from the path by a comma ‘ , ’
- and be outside the end quote if there is a space in the path:
path,index_number
"the path",index_number
c) If the file contains only one icon, then the index number is zero:
path,0
"the path",0
Tip
To find the index number of an icon from a file that has many, sometime hundreds, just personalize a folder with that icon (Right-click on a folder > Properties > Personalize tab > Change Icon...). Then, open the ‘desktop.ini’ file in that folder with a text program. Just copy the ‘Path,index_number’ that follows the instruction “IconResource=”.
The paths that have spaces are not quoted in the ‘desktop.ini’ file. Therefore, you must add them and make sure that the ending one is just before the comma
,index_number. Example:
"C:\Program Files (x86)\folder\program.exe",5
Note: The ‘desktop.ini’ is a Hidden System file. So, you might have to show it:
Window Explorer
> Tools
> Folder Options...
> View. In the [Advanced Settings] and under the little folder {hidden files and folders}, select (•) “show hidden files & folders”. OK.
3. Verification of your text file
⌊√⌉ It is easier and safer to make some corrections or changes in the file than messing up your registry.
- ⌊ ⌉ Is there any space in your New_Keys (first column)? There should be NO space.
- ⌊ ⌉ Is there any space in the Arrays of each Category? There should be NO space.
- ⌊ ⌉ Does each key and each separator in those Arrays separated by a ‘ ; ’ semi-colon?
- ⌊ ⌉ Are the paths with spaces quoted at both ends?
- ⌊ ⌉ Is the Icon index number separated from the path by a comma ‘ , ’ and is outside the last quote if there is one, i.e.,
path,index_number or "the path",index_number?
- ⌊ ⌉ The paths that have spaces are not quoted in the ‘desktop.ini’ file. Did you forgot to add the quotes,
and make sure that the ending one is just before the comma ,index_number?
- ⌊ ⌉ Did you picked up the ‘ = ’ character by mistake from the instruction “IconResource=” in the ‘desktop.ini’ file?
- ⌊ ⌉ Is there any typo in the extra words: command, Icon, MUIVerb and SubCommands?
1. Making backups of the branches that we will change
a) Open the Registry Editor: Start Menu
> write regedit
> click on the program “
Regedit.exe” above (right-click on it if you want to Pin it to the Start Menu for a while).
b) Go to the key
[HKEY_CLASSES_ROOT\DesktopBackground\Shell], select “
Shell” and bookmark it with the name:
DesktopBackground (See "Favorites" on the menu above).
c) Right-click on “Shell”
> Export
> name it Desktop_Background-today's date, choose the
Selected Branch option and OK.
d) Go to the key
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\CommandStore\shell]
e) Select “shell” and bookmark it with the name: CommandStore.
f) Likewise, right-click on “Shell”
> Export
> name it Command_Store-today's date, choose the Selected Branch option and OK.
2. Are your New_Keys unique in the context menu?
a) Check if each of your keys exist in the …\CommandStore\shell column. If it does, then change the name of your key in your text file under the “New_Keys” column AND in the Array. That will not affect what you want to see on your menu.
b) Click on your ‘DesktopBackground’ bookmark and check if your Title key exist. If it does, change its name under the “New_Keys” column.
3. Creating the main trigger on the first layer
Select-copy your equivalent of ‘TheTitle’ from your text file, then, Alt+Tab to switch to the register.
a) Right-click on the “Shell” key
> New
> Key. Paste your Title key as its new name.
b) Copy the word
MUIVerb from your file. Then, right-click on the empty space below “(default)”
> New
> String Value. Paste the word:
MUIVerb as its new name.
c) Copy The Title that you want to see from your file (
second column). Then, right-click on “MUIVerb”
> Modify...
> paste it.
Tip
If you want to center that name on your menu, just add a few spaces before it. Example:
" Cascade Menu" without the quotes.
d) Its ICON:
As you noticed, the menu opened by “Right-click
> New
> ” has many types of Value under "Key". When our action is on the right pane of the window, we will always choose the “String Value”, except when the Icon's Path starts with the ‘%’ character.
You see, that special character identifies a %variable% in the path. Therefore, we have to create a different type of value that can EXPAND to the real length of the path represented by that %variable%. Therefore, we choose an ‘EXPANDable’ value (the last one), which results as a “REG_EXPAND_SZ” in the [Type] column, instead of the usual “REG_SZ”. Make sense?
e) Copy your Title's Icon Path from your file.
f) On the right pane of your Title key, right-click on the empty space
> New
> String or Expandable Value. Name it:
Icon
g) Then, right-click on “Icon”
> Modify...
> paste its Path
,index_number.
h) Copy the word
SubCommands from your file. Then, right-click on the empty space
> New
> String Value. Paste the word:
SubCommands as its new name.
i) Copy the content of your first Array, the one of the three categories, from ‘TheTitle = [
Category1;Category2;Category3]’. Then, right-click on “SubCommands”
> Modify...
> paste your equivalent of Category1, Category2 and Category3.
CONGRATULATION‼ The first layer of the desktop menu is done! Try it!
You might want to adjust the position of your title by adding/removing a space in front of it (
right-click on “MUIVerb” > Modify... > … ). But I suggest for those who are still in Windows 7 to leave or put at least one space in front of every category and program's name. It separates them nicely from the too closed icons as oppose to the ‘Screen Resolution’, ‘Gadgets’, ‘Personalize’ ones. Compare the effect in my photos above.
4. Crafting the Cascade
This is the time to ship our new menu to the ‘Command Store’ and shift into a ‘Production Mode’. Click on your “CommandStore” bookmark to reach the key:
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\CommandStore\shell]
4.1
Creating all the Keys from your first column “New_Keys”.
We will create 16 New_Keys (four Categories and 12 Programs) by repeating this process.
a) Copy your equivalent of a Category/Program from your file.
b) Right-click on the “Shell” key > New > Key.
c) Paste it as its new name.
d) Use your bookmark to get back to the “Shell” key.
e) Repeat a) to d) for the remaining keys.
4.2
Creating the Values (names) on the right pane.
a) To the four Categories ONLY:
a1) Copy the word MUIVerb from your file.
a2) Select a category on the left pane.
a3) Right-click on the right pane on the empty space below “(Default)” > New > String Value. Paste the word: MUIVerb as its new name.
a4) Do the same to the remaining Categories.
a5) Copy the word SubCommands from your file.
a6) Repeat the steps a2 and a3 but with the word: SubCommands instead.
b) To both, Categories and Programs:
b1) Copy the word Icon from your file.
b2) Select a Category/Program on the left pane.
b3) Right-click on the right pane on the empty space > New > String or Expandable Value if there is a %variable% in the path. Paste the word: Icon as its new name. (See photos in Part 2, 3.d)
b4) Repeat the steps b2 and b3 for the remaining Categories and Programs.
4.3
Creating the “command” SubKeys.
a) Copy the word command from your file.
b) Leaving your Category Keys alone, right-click on the key of every Program you just made > New > Key. Paste the word: command as its new name. You have 12 programs to do.
5. Giving Life to your Cascade Context Menu of four layers!!
We are done creating keys and values. This final step is to assign a duty to each shortcut and where to get its icon.
5.1
Connecting the layers together.
a) Copy the name you want to see of the Category #1.
b) Select that Category on the left pane.
c) On the right pane, right-click on “MUIVerb”
> Modify...
> (
Windows 7: Press the space bar once before you) paste the name. The space is to separate the names nicely from the too closed icons in Windows 7.
d) Copy the content of the Array of that category, i.e., your equivalent of the Array "Category1 = [
Program1a;Program1b;Program1c;Program1d]"
e) On the right pane, right-click on “SubCommands”
> Modify...
> Paste that content.
f) Repeat the steps a) to e) for the remaining Categories.
Try your menu! It should cascade even if the programs are not listed yet! Great, isn't it? If it works, jump to the next process (5.2 Listing the shortcuts). Else, if the “Verification of your text file” in Part 1, section four went well, then, compare your file with your actions in the registry from the Part 2, section 2. If it still doesn't work, verify your text file again.
5.2
Listing the shortcuts.
a) Copy the name you want to see of a Program.
b) Select that Program's key on the left pane.
c) On the right pane, right-click on “(Default)” > Modify... > (Windows 7: Press the space bar once before you) paste the name.
d) Repeat the steps a) to c) for the remaining Programs.
∫ ̮ʼ̃ʖ Try your menu! It should cascade and list your programs‼ ̒̃८̡ ֹ̒̃ ͠ˀʅ
5.3
Giving the icon and the mission to each shortcut.
a) Copy the “Icon's path” of a program.
b) Select that Program's key on the left pane.
c) On the right pane, right-click on “Icon” > Modify... > Paste its path (with the icon index number).
d) If the icon comes from that program, continue. Else, copy the “Program's path”.
e) Select the “command” key of that Program on the left pane.
f) On the right pane, right-click on “(Default)” > Modify... > Paste the path, delete the ",index_number" of the Icon's path, including the ‘ , ’ character. OK. Be careful not to delete the end quote of the paths that need to be quoted.
g) Repeat the steps a) to f) for the remaining Programs.
h) Close the Registry editor. Voilà‼
٩̢ ̗(Ӧ̮Ӧ)ʅ۶Enjoy YOUR desktop Cascade Context Menu of four layers‼ ̒¿ ̡̒ ˀʅ
6. The Changes
You will eventually want to change or remove a program, a category, a separator or an icon. I recommend to make your changes in your text file first. But before you do so, copy & paste at the end: the
template, the
Arrays and the
special words, then, edit that section instead. That will keep your original intact in case you make some mistakes.
Once ready to edit, double-check your changes with Part 1, section 3: “
Verification of your text file”. Then, start your editing from Part 2, section 1: “
Making backups of the branches that you will change.”