From fcb710a48aed6a69eacf574e6a16c559953de4e6 Mon Sep 17 00:00:00 2001 From: WindowsAddict Date: Tue, 5 Nov 2024 22:23:02 +0530 Subject: Add an error code to detect WMI error --- MAS/Separate-Files-Version/Troubleshoot.cmd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'MAS/Separate-Files-Version/Troubleshoot.cmd') diff --git a/MAS/Separate-Files-Version/Troubleshoot.cmd b/MAS/Separate-Files-Version/Troubleshoot.cmd index 40e6489..131daa6 100644 --- a/MAS/Separate-Files-Version/Troubleshoot.cmd +++ b/MAS/Separate-Files-Version/Troubleshoot.cmd @@ -1078,7 +1078,7 @@ if %errorlevel% NEQ 0 (set error=1& exit /b) %psc% "try { $null=([WMISEARCHER]'SELECT * FROM SoftwareLicensingService').Get().Version; exit 0 } catch { exit $_.Exception.InnerException.HResult }" %nul% cmd /c exit /b %errorlevel% -echo "0x%=ExitCode%" | findstr /i "0x800410 0x800440" %nul1% +echo "0x%=ExitCode%" | findstr /i "0x800410 0x800440 0x80131501" %nul1% if %errorlevel% EQU 0 set error=1 exit /b -- cgit v1.2.3