Question

I need a little desktop shortcut that I could click with a mouse. It needs to perform the action WINDOWS+D.

I was told that I could build a .VBS file to create a desktop shortcut but I have absolutely no idea how to do so. I'm clueless about coding and this sort of tech stuff.

All I could find was this:

Set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.SendKeys "^+{ESCAPE}"

Theoretically I could just replace those values for WINDOWS+D, but I don't know their correspondent strings.

So, how can I accomplish that?

Thanks!

Was it helpful?

Solution

Instead of that, why not try:

Set shell = wscript.CreateObject("Shell.Application")
Shell.MinimizeAll
Set Shell = nothing

Or maybe:

set Shell = wscript.CreateObject("Shell.Application")
Shell.ToggleDesktop
Set Shell = nothing

I don't have a Win 8 machine to test with right now. Let me know if it works.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top