In the local Group Policy Editor, go to the Start menu and taskbar "Administrative user configuration templates" and double click on "Remove" and select the "Prevent shutdown", "Reboot", "Enter hibernate" and "Sleep" commands. Now you want to enable this setting and click Apply and OK.