I am writing an application that should create a special user account hidden from the login screens and the applet of the control panel users. By writing a DWORD value of 0 with the username in the registry key below, I can perform this task:
HKEY_LOCAL_MACHINE \ SOFTWARE \ Microsoft \ Windows NT \ CurrentVersion \ Winlogon \ SpecialAccounts \ UserList
The problem is that on Windows 7 with UAC, no matter what I try, I cannot programmatically write the value for the key above.
I understand that writing to specific keys is not allowed on Windows 7 with UAC unless you use Administrative privileges. I added the application manifest requestedExecutionLevel level="requireAdministrator" uiAccess="false" , I accept the UAC prompt when my program is running, my account is a member of the Administrators, but I still can not write this registry key.
What else do I need to do? How can I write keys and values โโin HKEY_LOCAL_MACHINE\SOFTWARE in any application configuration?
Additional information ... When my program starts, there are no errors, and it seems that they write values. I assume Windows is virtualizing the location I'm writing to. I need to write the actual location, not virtual, if I want to hide this special user account.
sysrpl
source share