If you have multiple displays or an external projector, you might be familiar with the built-in feature of Windows 7 and Windows 8 to change the active display and the sharing mode of your current desktop. When you press Win+P, you can choose to extend your desktop, duplicate it, or turn off one of the displays entirely. It is possible to control this feature via the command line, so you can create a shortcut any of these 4 settings. Let's see how it can be done.
The built-in Windows utility, DisplaySwitch.exe, allows you to specify which display to use and how to use it.
It supports the following command line arguments:
The /internal argument is used to switch your PC to use the primary display only.
Tip: You can try these options right in the Run dialog. Open it with the Win + R shortcut and type the command above in the Run box.
Use this command to switch to the external display only.
Duplicates the primary display
Expands your Desktop to the secondary display
That's it. Now you can create a shortcut with the appropriate command.
You can assign a global keyboard shortcut as described in the article: Add global hotkeys to launch your favorite applications in Windows 8.1.
Winaero greatly relies on your support. You can help the site keep bringing you interesting and useful content and software by using these options:
oh cool! thanks!
Thank you! I’ve been looking for this solution for ages :)
Pressing the spacebar performs direct Disolayswitch.exe. How do I put it back, I never created a shortcut.
My laptop has two external graphics ports, but only one can be active at a time. I have the HDMI going to my TV and the VGA to a small monitor on my desk. With the laptop screen as primary, can I use DisplaySwitch to pick which one will be active and which one will be disconnected?
Once I was just trying commands in command prompts I tried the command as “Displayswitch”
And accidentally click on “projector only”.
The problem is I don’t have a projector and the moniter is not displaying anything.
How can I make it back to moniter for displaying purpose
Today I was searching some blogs on Google related to technology, when I searched on Google, I went to some websites and saw their blogs but I could not find the type of blogs I wanted to see, I did some search again and when I came to your website and I liked your blogs very much, I enjoyed reading your blogs.