# 1. Display Current Windows Version Write-Host "--- Current Windows Version ---" -ForegroundColor Cyan Get-ItemProperty "HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion" | Select-Object ProductName, DisplayVersion, CurrentBuild Write-Host "" Start-Sleep -Seconds 5 # 2. Inspect Registry Folder Contents $path = "HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate" Write-Host "--- Inspecting Registry Path: $path ---" -ForegroundColor Cyan if (Test-Path $path) { Get-ItemProperty -Path $path | Format-List } else { Write-Host "Registry path does not exist." -ForegroundColor Yellow } Write-Host "" Start-Sleep -Seconds 5 # 3. Delete Specific Registry Entries Write-Host "--- Deleting Specified Entries ---" -ForegroundColor Cyan $itemsToDelete = @("ProductVersion", "TargetReleaseversion", "TargetReleaseversionInfo") foreach ($item in $itemsToDelete) { if (Get-ItemProperty -Path $path -Name $item -ErrorAction SilentlyContinue) { Remove-ItemProperty -Path $path -Name $item -Force Write-Host "Successfully deleted: $item" -ForegroundColor Green } else { Write-Host "Item not found or already deleted: $item" -ForegroundColor Gray } } usoclient StartInteractiveScan