For more information about openkey, see! Delphi/Windows SDK/API 
Http://www.delphi2007.net/DelphiAPI/html/delphi_20061106111720296.html 
I wrote a loan code to disable the USB flash drive. 
VaR 
Reg: Tregistry; 
Begin 
Reg. rootkey: = HKEY_LOCAL_MACHINE; 
If Reg. openkey ('\ System \ CurrentControlSet \ Services \ usbstor', true) then 
Begin 
Reg. writeinteger ('start', 4 ); 
Reg. close; 
Reg. Free; 
End 
Else showmessage ('error '); 
 
End; 
 
But what I don't understand is that it runs normally under the administrator user and can lock the USB flash drive. however, running in a power users user shows a 'error'. I also saw that this key exists under this user, but it cannot be used.  Program Change the settings (it seems that the openkey cannot be found). This is really strange. Please help us to see why. Thank you. 
 
 
 
 
 
 
 
 
 
The user in the Power Users Group has no permission to modify this key value.
 
 
To do2008 (the thing is done) () reputation: 100 blog
I still don't understand. How should I modify it ?. I think if an EXE file is generated, it should be run in the same way under any user?
 
 
 
I think if an EXE file is generated, it should be run in the same way under any user.
========================================================== ========================================================== ===
Some system settings only support administrator, and your program can be modified by the administrator user. Other users cannot modify the program, which means other users do not have the permission to modify the key value, unless you redefine other user permissions as administrator permissions
 
 
 
Maozefa (AFA )~~~ Positive Solution ~~~
In Windows, Administrators have the highest permissions for Windows and can execute important system configurations;
However, other user group members may not have relevant permissions. If all users, such as guest and users, have permissions,
Windows does not need to be mixed up ~~~
For which operations require permissions, You need to query relevant information, such as msdn ~~~
 
 
 
Run regedit.exe and use the tool menu to modify this permission.