prevent monitor switching when closing laptop lid

23

17

I got one of those little lilliput external monitors for my laptop. When I close the lid on my laptop, it switches the primary display to external monitor. I want to prevent it from doing this, and instead just blank both screens but not alter the monitor configuration.

I looked at the Power Options "Change what to do when closing the lid" option, but that just gives options for Sleep, Hibernate or Do Nothing. I want to Do Nothing, and prevent the monitor reconfiguration. Any ideas?

Thanks in advance!

Oh, BTW, I'm running Windows 7 Ultimate on an Alienware with the ATI graphics card.

CLARIFY: My reasoning for this question is that I often carry my laptop back and forth between rooms, but not far enough that I'm going to shut it down and restart. Normally I just closed the lid and picked it up. The problem is, now when i close the lid, it switches the primary display to the external, and then when i reopen it, it switches back to the internal monitor. This then winds up futzing up layout things, such as gadgets and sticky notes.

eidylon

Posted 2009-12-28T16:14:45.120

Reputation: 1 667

Unplug the external monitor before you close the lid and move. – Enigma – 2013-04-02T15:41:16.030

Answers

15

EDIT: I know this is an old question, but I thought it deserved a proper answer.

There is a way to solve this problem (at least with Windows 7). Bear in mind that this comes with a cost; here are the caveats

  1. Closing your laptop lid will not dim or turn off the screen.
  2. You have to change a device driver, which may be a bit scary for some people

Despite the above cons, I think the benefits outweighs it by a lot. There are ways to combat the first caveat too:

  • Set your monitor to dim in one minute and for it to turn off in 2 minutes within Power Options. That way, the monitor will not be unnecessarily on when you're not using the computer for more than 2 minutes. (this won't help if you're still using the other monitor)
  • Also, take a look at this link to create a shortcut to turn off your monitor.

I'm using a MacBook with Bootcamp; luckily, I can just turn down my brightness all the way so that it dims the screen completely. Some other laptop models may be able to do that as well.

Here are the steps:

  1. Open Device Manager (search it in the Start menu).
  2. In "System devices" find "ACPI lid".
  3. Open "ACPI lid" properties, and go to the "Driver" tab.
  4. Select "Update driver".
  5. Choose "Browse my computer for driver software" and "Let me pick.."
  6. Uncheck "Show compatible hardware".
  7. In "Manufacturer" select "(Standard system devices)", or in Windows 8, choose Microsoft as the manufacturer - different place, but the hack still works (at least in the 64bit Release Preview)
  8. For model, select "Volume manager".
  9. Restart the system and it works!

Source: http://forums.whirlpool.net.au/archive/1421975 - yakup's post

Steve

Posted 2009-12-28T16:14:45.120

Reputation: 991

1Confirmed working on Win 10. Does anyone know how and why it works? – Sirap – 2017-01-03T03:17:58.520

@Sirap This is just a guess, but we basically screw up how Windows interacts with the lid itself. When it closes, I'm guessing the driver for the lid tells windows to disable the display/monitor. Since we change the driver to use some random driver (Volume Manager), the lid can't communicate this properly. – Steve – 2017-01-03T06:50:26.370

2@Steve You are a God among men. – Ram Rachum – 2017-04-16T18:48:39.533

1For anyone finding this now in 2020 this still works on windows 10 Home +1 – TyBourque – 2020-01-10T18:46:58.907

Just did it for my 8 month old Windows 10 laptop. It works, select manufacturer as MS that's it. – Karan Raj Baruah – 2020-02-05T17:11:22.610

This also works if you are suffering from the ATI drivers switching on the laptop screen when you open the lid - if like me you just open the lid to power on the laptop and keep to connected to an external monitor. You can always use Windows Key + P to manually switch back to the laptop screen should you need it. – yummer – 2012-08-07T13:41:03.767

1Now THIS solved the problem, thanks! Interestingly, my laptop still dims itself when the lid is closing, so no need to set the Power options. – István Zachar – 2012-09-24T22:19:49.930

3

The solution by Brett via Powershell (if you're too lazy)

To execute it:

  1. save script in some folder (LidAlwaysOpen.ps1)
  2. run cmd.exe as administrator
  3. type powershell
  4. type Set-ExecutionPolicy RemoteSigned (this will allow execution of Powershell stuff on your machine only)
  5. cd to folder you've saved script
  6. type ./LidAlwaysOpen.ps1

Script code:

foreach ($display in Get-ChildItem -Path Registry::HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Video) {
 New-ItemProperty -LiteralPath Registry::$display\0000 -Name LidAlwaysOpen -PropertyType DWORD -Value 1
}

raggzy

Posted 2009-12-28T16:14:45.120

Reputation: 31

2

For Windows 7:

  1. Open the registry editor (regedit.exe)
  2. Navigate to the following key (you will have to identify the correct GUID for your display):

    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Video\{********-****-****-****-************}\0000
    
  3. Create a new DWORD called LidAlwaysOpen and set its value to 1
  4. Reboot

Brett

Posted 2009-12-28T16:14:45.120

Reputation: 21

Identifying the display can be helped by clicking on each display i.e. '0001', and look at what it relates to. For a laptop, look for a reference to its graphics card. Then the laptop's display will be 0000 and any attached displays 0001+. – J Collins – 2015-03-28T13:27:12.633

2Some user have been reported this will work only for first lid closure, but not for subsequent ones. – Andrejs Cainikovs – 2011-02-25T11:57:13.067

1"you will have to identify the correct GUID for your display" That's the part I'm TRYING TO FIGURE OUT!! HOW do you do such a thing?! -- Also, what do you do if you can't find a matching GUID in the list?! – Tustin2121 – 2013-03-24T05:36:10.800

1

Just to add to rob's answer. For example, on my hp 6715 there is a button (literally, a small button) which can be plainly seen (is a little above the wireless button) and the laptop top literally presses it when it is closed. If you have a similar on your you could theoretically cut it in half or something, and then it wouldn't turn off when the lid is closed.

However, this is highly (with a capital H) unrecommendable ...

Rook

Posted 2009-12-28T16:14:45.120

Reputation: 21 622

Most modern laptops use a magnetic switch these days but if you do happen to have a specific need for a hardware workaround, disconnecting said switch would be one solution I guess. – qasdfdsaq – 2018-05-30T19:18:03.940

I like that word - "unrecommendable"! LOL . Thanks for the idea, but there is no physical button on my laptop, it must be one of these magnetic things, or something built inside the lid hinges or something. – eidylon – 2009-12-30T03:23:41.233

oh, well ... it was worth a shot :) so far i've seen it pretty common on laptops, so i gathered that being the usual system ... now, i guess, everyone got its own ... – Rook – 2009-12-30T03:41:38.517

0

As far as I know, the laptop will always switch the built-in display off and reconfigure the external display as the primary when you close the lid. If it didn't, you would end up with programs and dialogs opening on the built-in display, but you would have no way to see them.

When you open the lid again, it should reconfigure the displays so the built-in is once again the primary.

The only ways I can think of to force the displays not to reconfigure are to either not close the lid all the way, or disable the mechanical or magnetic switch that detects when the lid has closed.

rob

Posted 2009-12-28T16:14:45.120

Reputation: 13 188

I agree with Rob. In addition, a quick hit of Win+P will allow you easily select Extended mode again if that's what you need. – Mark – 2009-12-28T19:39:31.350