I am using Windows 8.1 and I have set a child account for my son. When he wants to use the computer, I switch to his child account without signing out from my account (because i have a lot of open documents that I still work on and don't want to close them yet). One day, when he finishes using the computer, he shut down the computer immediately. When the computer is shut down, I lose all of my open documents. It is a disaster indeed. Is there a way to disable child account's power button at the charm bar or at least to disallow shut down if other accounts are still on?
2 Answers
Solution
There are different ways to shutdown the system, so you have to take that into account in order to avoid the issue entirely.
Preliminary steps
- Make sure the user accounts you want to restrict are logged off.
- Log on with an administrator account, and open an elevated command prompt.
Disable all shutdown buttons and menus for a specific user
Type or paste the following command in the command prompt by replacing
<User>
with the actual folder, then press Enter:reg load "HKU\User" "%SystemDrive%\Users\<User>\NTUSER.DAT"
Execute the commands below:
reg add "HKU\User\Software\Microsoft\Windows\CurrentVersion\Policies\Explorer" /v "NoClose" /t REG_DWORD /d 1 /f reg unload "HKU\User"
Repeat steps 1-2 for any other user you want to limit.
Revoke shutdown privileges assigned to standard users
Download the Windows Server 2003 Resource Kit Tools.
Extract the
rktools.exe
downloaded file using 7-Zip.Open the folder containing the extracted files, and extract the
rktools.msi
through 7-Zip. Among all the files there's one calledntrights.exe
.Navigate to the folder containing
ntrights.exe
by running the commands below after replacing the folder path inside quotes:cd /d "X:\Some\folder" ntrights.exe -u Users -r SeShutdownPrivilege ntrights.exe -u Users -r SeRemoteShutdownPrivilege
Remove shutdown button on the logon screen
Execute this command:
reg add "HKLM\Software\Microsoft\Windows\CurrentVersion\Policies\System" /v "ShutdownWithoutLogon" /t REG_DWORD /d 0 /f
References
- Command Prompt: frequently asked questions
- reg - Command-Line Reference
- NTrights - User Privileges | SS64.com
- Remove and prevent access to the Shut Down, Restart, Sleep, and Hibernate commands
- Shut down the system - User Rights Assignment
- Shutdown: Allow system to be shut down without having to log on
-
Thank you. I think this solution works better. It prevents my child's account, and possibly other accounts, to shutdown computer but allows me to turn it off by using my own account without hassle. I think I am also a little bit encouraged to delve into this ntrights.exe. Feb 23, 2014 at 2:42
Try the following.
- Press
+ R and put
gpedit.msc
in Run dialog box. Press Enter. - In Group Policy window will pop up from which choose
User Configuration
-Administrative Templates
-Start Menu & Taskbar
from the Left Panel as shown below..
- Now on the Right Panel, double-click on
Remove And Prevent Access To Shut Down Command
. - A pop will appear set it to
Enabled
. Then you’ll notice that this will remove the shutdown option from the Start Menu and security dialog box.
-
Your tutorial is about disabling shutdown button on logon screen. This is actually not my problem because my son shuts down Windows using power button on the charm bar (the black bar that pops up on the right) after he is logged on his child account. Usually, when you shut down computer while there are other users who are logged on, Windows will show a warning saying "Someone else is still using this PC. If you shut down now, they could lose unsaved work." I can say that this warning is useless because the shut down process can still proceed with a press of button, which my son can easily do. Feb 20, 2014 at 13:37
-
-
@TiagoƇ. Those steps won't really disable the charms bar, which would still be accessible by using the keyboard shortcut (Win+I). Also, there are other ways to shutdown Windows.– and31415Feb 20, 2014 at 15:47
-
@and31415 I rephrase the answer, see if the shutdown is still accessible. Thank you.– stderrFeb 20, 2014 at 16:31
-
1@TiagoƇ, thank you. I know that there are many interesting hidden things in the Group Policy. I am using Pro edition, so I don't have problem with accessing GP editor. But do I have to open GPedit whenever I want to switch account between mine and my son's? Those steps indeed disable access to power options on the charm bar (they even disable access to Alt+f4), so when I leave the policy you mention always enabled, I myself cannot shutdown the computer using my account without firstly disabling that policy. But thanks anyway. at least i can keep my data secured when I switch account. Feb 23, 2014 at 2:27