Change display settings on Workstation lock

kirua

New member
Local time
10:22 PM
Messages
2
Hi,

What I'm trying to do is to clone my display at workstation lock and switch to internal or external display at workstation unlock depending on the user.

I found a solution in another post : http://www.sevenforums.com/customization/94917-locked-computer-dual-monitor-3.html

The method 2 described seems to match my case but I can't manage to make it work... I created the tasks but nothing happen when I do Win+L...

Here is the description of the method :

@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@

METHOD 2: Scheduled Triggers
This workaround involves changing the display to duplicate screens when you lock your computer and changing it back to 2 screens when you unlock it.

To do this, we'll use task scheduler to run some command lines on a trigger. The triggers will be either unlock or locking of the computer.
%windir%\System32\DisplaySwitch.exe /extend to use two screens
%windir%\System32\DisplaySwitch.exe /clone to clone the screens
or we could also use
%windir%\System32\DisplaySwitch.exe /internal to use just one screen


So lets set this up
Create the First Task
  1. Open the task scheduler by typing taskschd.msc into RUN or SEARCH and pressing ENTER
  2. Right Click on Task Scheduler (Local) and select 'Create Task'
  3. In the Create Task Window Type a Name for first the task (e.g. Single Display Lock)
  4. Type in a description (E.g. This task is triggered when Windows is locked and changes the display to a single display)
  5. Tick the 'Run with Highest Privilages' Box
  6. Change the 'Configure for' drop down box to "Windows 7, Windows Server 2008 R2"
  7. Select the TRIGGERS tab
  8. Click NEW
  9. In the Begin the Task Dropdown select "On workstation lock"
  10. in The Advanced Settings Select the "Delay Task for" box and type 3 Seconds in the box beside it. NOTE: you may need to increase this if it doesn't work for you.
  11. Click OK
  12. Select the ACTIONS tab
  13. Click NEW
  14. In the Program/Script box type the following %windir%\System32\DisplaySwitch.exe
  15. In the Add Arguments box type /clone
  16. Click OK
  17. Select the CONDITIONS tab
  18. Click OK to save and exit the new task

Create the Second Task
  1. Open the task scheduler by typing taskschd.msc into RUN or SEARCH and pressing ENTER
  2. Right Click on Task Scheduler (Local) and select 'Create Task'
  3. In the Create Task Window Type a Name for first the task (e.g. Extended Screen for Unlock)
  4. Type in a description (E.g. This task is triggered when Windows is unlocked and extends the screen to two monitors)
  5. Tick the 'Run with Highest Privilages' Box
  6. Change the 'Configure for' drop down box to "Windows 7, Windows Server 2008 R2"
  7. Select the TRIGGERS tab
  8. Click NEW
  9. In the Begin the Task Dropdown select "On workstation unlock"
  10. in The Advanced Settings Select the "Delay Task for" box and type 3 Seconds in the box beside it. NOTE: you may need to increase this if it doesn't work for you.
  11. Click OK
  12. Select the ACTIONS tab
  13. Click NEW
  14. In the Program/Script box type the following %windir%\System32\DisplaySwitch.exe
  15. In the Add Arguments box type /extend
  16. Click OK
  17. Select the CONDITIONS tab
  18. Click OK to save exit the new task

It takes a few seconds to come up but it should work a-ok.

@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@

If anyone could help ? Thanks !
 

My Computer My Computer

Computer type
PC/Desktop
OS
Windows 7 Ultimate x64
anyone ?
 

My Computer My Computer

Computer type
PC/Desktop
OS
Windows 7 Ultimate x64
I have never tried that, but I would try method 3
 

My Computer My Computer

Computer type
PC/Desktop
Computer Manufacturer/Model Number
Dude Build
OS
Windows 10 Pro X64
CPU
Intel(R) Core(TM) i5-3570K CPU OC@ 4.5GHZ Turbo
Motherboard
MSI Z77A-G45 Gaming
Memory
8.00 GB DDR3 1600Mhz
Graphics Card(s)
MSI Gaming X GTX 1070
Sound Card
Realtek High Definition
Monitor(s) Displays
Dell S23O9W, HP L1710
Screen Resolution
DELL-1920 x 1080 HP-1280 x1024
Hard Drives
Crucial m4 256 SSD, WD 7200RPM 500GB WD 1TB
PSU
Seasonic X650 GOLD
Case
Zalman Z12
Cooling
Antec Kuhler 920
Keyboard
Logitech
Mouse
MSI DS100 Interceptor
Internet Speed
50 down and 5 up
Antivirus
MSE
Browser
Chrome, IE 11
Other Info
Logitech X-620 Speakers
Back
Top