This commit is contained in:
2022-11-23 15:59:33 -05:00
parent 855f186aba
commit 9d4739beba
+13
View File
@@ -744,5 +744,18 @@ function EnumUserProfiles {
Return $UserProfilePaths
}
# Function to test for the presense of a Registry property
function Test-RegistryProperty {
param(
[Parameter(Mandatory=$true)][string]$Path,
[Parameter(Mandatory=$true)][string]$Name
)
Try {
Get-ItemProperty -Path $Path | Select-Object -ExpandProperty $Name -ErrorAction Stop | Out-Null
Return $true
}
Catch { Return $false }
}
Setup-MSPDirectories
Setup-LogFile