Windows 10 normally puts your laptop in sleep mode when you close the lid. This can be a problem if you connect your laptop to an external monitor. Use the Control Panel – not the Windows 1
If you do, be careful! If you close the lid of your laptop and throw it in your pocket while it is still on, it can cause serious problems because air circulation is poor or the openings are blocked. Your laptop keeps on running, wastes the battery and can even overheat in your pocket. You must manually put your laptop to sleep, put it to sleep, or shut it down using the power buttons or the Start menu options instead of simply closing the lid. Close the lid, right-click the battery icon in the system tray, and then click "Power Options."
 If the battery icon does not appear, click Show Hidden Icons, and then right-click Right-click the battery icon – or go to Control Panel> Hardware and Sound> Power Options.
 Then click in the window on the left side on "Choose what to close the lid".
Ultimate Power Plan in Windows 10
In the drop-down menu for "When I close the lid" s Select " Do nothing".
There are two different options: battery and connected. You can choose different options for each. For example, you might want your laptop to remain on when you close the lid while it's plugged in, and you're in hibernation when the battery is charged.
The settings you have selected are assigned to your Windows power plan.
. Warning: Remember, if you change the "On Battery" setting to "Do Nothing", make sure your laptop is shut down or overheated when you put it in your sleeping bag or in hibernation when you put it in your pocket to avoid.
After making the changes, click "Save Changes" and close the Control Panel.
You should now be able to close the lid of your laptop without enabling sleep mode. If you want to reset any of the settings to the default settings, go back to Control Panel> Hardware and Sound> Power Options and change them back.