Windows – Set UAC Level with PowerShell

powershelluacwindows 7windows-registry

I'm looking for a way to set the UAC Level with Powershell/Command prompt. I'm aware the 'EnableLUA' value in the registry, but this won't set the level. It's just true or false.

Is there a way to set the UAC Level with Powershell? With level, I mean the four levels of UAC. They go from 'Never Notify' to 'Always Notify".

Thank you.

Best Answer

There are several registry values that control User Account Control:

  1. FilterAdministratorToken
  2. ConsentPromptBehaviorAdmin
  3. ConsentPromptBehaviorUser
  4. EnableInstallerDetection
  5. ValidateAdminCodeSignatures
  6. EnableLUA
  7. PromptOnSecureDesktop
  8. EnableVirtualization

The combination of these values is what controls the slider in the GUI, or vice-versa.

Reference: http://msdn.microsoft.com/en-us/library/cc232771.aspx

Related Question