Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have my tv connected to my Windows XP pc's nvidia GeForce 8500 GT.

I am constantly switching between single display and clone display.

Is there a way to script these settings? I would be fine with writing a batch file or a .net program to do it.

When I want to use my tv I right click the nVidia tray icon -> nView Display Settings -> Clone -> TV + Acer Monitor

When I want to switch back to only my moniter, I right click the nVidia tray icon -> nView Display Settings -> Single Display -> Acer Monitor

share|improve this question
I wish ATi's monitor switching was that streamlined. They make you pull up a five step wizard. – JamesGecko Aug 2 '09 at 7:52
up vote 2 down vote accepted

Combined with AutoIT, AutoHotkey or a batch script, this PDF-document (Command Line Functions => Using DTCFG-Configuring the Desktop => DTCFG Desktop Configuration Commands) may be of great assistance.

From that I tried to create a simple AutoHotkey-script, but I am not sure if it works, nor if it does what you want.

single = 1
;----- Ctrl-F2, change to whatever you see fit
;----- cloning to screen 2
if (single = 1) {
    run rundll32.exe NvCpl.dll`,dtcfg setview 1 clone,,Hide
    single = 0
} else {
;----- back to primary only
     run rundll32.exe NvCpl.dll`,dtcfg setview 1 standard,,Hide
     currentMode = 2
share|improve this answer

You could use AutoHotkey or AutoIT script to make an automated version. The AutoIT documentation has an excellent guide on automating GUIs. (AutoHotkey probably has something similar, but I am not familiar with it)

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .