When you close the lid on your mobile PC, Windows can shut down, do nothing, or enter a power-saving state, such as sleep or hibernation. You can apply the same setting to all of your power plans or you can apply different settings to individual plans.
Open Power Options by clicking the Start button , clicking Control Panel, clicking System and Maintenance, and then clicking Power Options.
On the Select a power plan page, click Choose what closing the lid does.
On the Define power buttons and turn on password protection page, next to When I close the lid, choose what you want your mobile PC to do, both for when it is running on battery and when it is plugged in.
To save battery power and quickly resume working, select Sleep. When you wake your mobile PC, Windows restores your work session within seconds.
Click Save changes.
On the Select a power plan page, click Change plan settings for the plan that you want to change.
On the Change settings for the plan page, click Change advanced power settings.
On the Advanced settings tab, expand Power buttons and lid, expand Lid close action, and then choose what you want your mobile PC to do when you close the lid, both for when your mobile PC is running on battery and when it is plugged in.