Windows 7 has moved the “Show Desktop” button the right-hand side of the taskbar. But, for those that prefer, a classically positioned button can be created.
The first thing to do is create a script that launches the “ToggleDesktop” command. Create a new text file. Change the file extension from .txt to .scf. Edit the file with a text editor and add the following text (“IconFile” key is optional):
[Shell] Command=2 IconFile=shell32.dll,34 [TaskBar] Command=ToggleDesktop
Save the file and close the text editor. You should now be able to double-click the script and it will iconize any visible windows and show the desktop. If you want to be able to execute the script from the command line place it in a folder on the system path (usually C:\Windows or C:\Windows\System32).
Now that the script is created we can add it to the taskbar. Find any regular executable on your system. A good option is C:\Windows\notepad.exe. Launch the executable. Right click its icon in the taskbar and select “Pin to taskbar”.
Change Executable Path Win7:
(For ViGlance users skip down to the section called “Change Executable Path ViGlance”)
Right-click the icon again and select “Properties”. Change “Target” to the location where you saved your .scf script (Example: C:\Windows\ShowDesktop.scf) and click “OK” or “Apply”.
Change Executable Path ViGlance:
Turn off ViGlance: Right-click its icon in the system tray and select “Exit”. Open ViGlance’s settings file in a text editor. This is located in “%AppData%\ViGlance\options.ini” (“C:\Users\Username\AppData\Roaming\ViGlance\options.ini” for Vista users). At the bottom of the text there will be a list of items that are pinned to the taskbar headed with “[ShellLink_X]”. The most recently pinned item (notepad.exe in this case) will probably be the very last. Change the line “Path=C:\Windows\notepad.exe” to the path where the .scf script is located (Example: “Path=C:\Windows\ToggleDesktop.scf”). Now re-start ViGlance. The pinned notepad should now execute the ShowDesktop script and have a different icon (if you set the icon key in the script).
Click the new icon and it should now execute the ToggleDesktop command. Move the icon to the desired position next to the start menu
NOTE: The following video contains a minor error concerning setting up ViGlance. It is not necessary to create a native executable (or .bat script) to pin to the taskbar. ViGlance will accept a .scf script. I plan to re-record this at a later date.