If you're got a laptop or PC running Microsoft's Windows operating system, you may find it's possible to push the power button or close the lid to put your device to sleep, make it hibernate or even to shut it down. However, if perhaps closing the lid shuts down your machine and you'd rather it simply put it to sleep, fear not. It's very easy to adjust what these actions do. Here's how to change what the power button does in Windows 7.
From the Start menu open the Control Panel.
Choose Hardware and Sound and then from underneath Power Option select Change hat the power buttons do.
You'll be presented with three different activities; When I press the power button, When I press the sleep button and When I close the lid. Next to each of these will be a drop down menu featuring four different actions; Do nothing, Hibernate, Sleep and Shut down. Simply select the action you'd like the button to perform. If you're running Windows 7 on a laptop you will see these actions for both when the PC is powered by a battery and when it is plugged in to the mains.
Furthermore, you can also enable password protection so that when the computer wakes up from sleep mode you must enter the password on the user account to activate it again. Press Require a password or Don't require a password as appropriate. Now press Save changes for your adjustments to be saved.