13 lines
517 B
PowerShell
13 lines
517 B
PowerShell
# Specify the registry path and new DWORD value information
|
|
$registryPath = "HKCU:\Software\Microsoft\Windows\CurrentVersion\CapabilityAccessManager\ConsentStore\location"
|
|
$valueName = "ShowGlobalPrompts"
|
|
$valueData = 0
|
|
|
|
# Check if the registry key exists
|
|
if (!(Test-Path $registryPath)) {
|
|
# Create the registry key if it doesn't exist
|
|
New-Item -Path $registryPath -ItemType RegistryKey -Force
|
|
}
|
|
|
|
# Set the DWORD value
|
|
Set-ItemProperty -Path $registryPath -Name $valueName -Value $valueData -Type DWORD -Force |