1
0
mirror of https://github.com/massgravel/Microsoft-Activation-Scripts.git synced 2025-02-24 13:43:15 +00:00

9 Commits

10 changed files with 134 additions and 96 deletions

6
.gitattributes vendored
View File

@ -1,4 +1,4 @@
MAS export-ignore # MAS export-ignore
LICENSE export-ignore # LICENSE export-ignore
README.md export-ignore # README.md export-ignore
.gitattributes export-ignore .gitattributes export-ignore

View File

@ -1,4 +1,4 @@
@::RANDOM-09dbb08f-d896-4653-b84f-24fc22f8d250 @::03938c58-ded9-4e95-b879-cb81e3e77c93
@set masver=2.7 @set masver=2.7
@setlocal DisableDelayedExpansion @setlocal DisableDelayedExpansion
@echo off @echo off
@ -1458,9 +1458,9 @@ call :dk_color2 %Red% "Checking Boot Mode [%safeboot_option
for /f "skip=2 tokens=2*" %%A in ('reg query "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Setup\State" /v ImageState') do (set imagestate=%%B) for /f "skip=2 tokens=2*" %%A in ('reg query "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Setup\State" /v ImageState') do (set imagestate=%%B)
if /i not "%imagestate%"=="IMAGE_STATE_COMPLETE" ( if /i not "%imagestate%"=="IMAGE_STATE_COMPLETE" (
set error=1 call :dk_color %Gray% "Checking Windows Setup State [%imagestate%]"
call :dk_color %Red% "Checking Windows Setup State [%imagestate%]"
echo "%imagestate%" | find /i "RESEAL" %nul% && ( echo "%imagestate%" | find /i "RESEAL" %nul% && (
set error=1
set showfix=1 set showfix=1
call :dk_color %Blue% "You need to run it in normal mode in case you are running it in Audit Mode." call :dk_color %Blue% "You need to run it in normal mode in case you are running it in Audit Mode."
) )
@ -1687,6 +1687,7 @@ for /f "delims=" %%a in ('%psc% "(Get-ScheduledTask -TaskName 'SvcRestartTask' -
echo !taskinfo! | find /i "Ready" %nul% || ( echo !taskinfo! | find /i "Ready" %nul% || (
reg delete "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SoftwareProtectionPlatform" /v "actionlist" /f %nul% reg delete "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SoftwareProtectionPlatform" /v "actionlist" /f %nul%
reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Schedule\TaskCache\Tree\Microsoft\Windows\SoftwareProtectionPlatform\SvcRestartTask" %nul% || set taskinfo=Removed reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Schedule\TaskCache\Tree\Microsoft\Windows\SoftwareProtectionPlatform\SvcRestartTask" %nul% || set taskinfo=Removed
if "!taskinfo!"=="" set "taskinfo=Not Found"
call :dk_color %Red% "Checking SvcRestartTask Status [!taskinfo!, System might deactivate later]" call :dk_color %Red% "Checking SvcRestartTask Status [!taskinfo!, System might deactivate later]"
) )
) )
@ -1829,7 +1830,7 @@ echo:
if %_unattended%==1 timeout /t 2 & exit /b if %_unattended%==1 timeout /t 2 & exit /b
if defined fixes ( if defined fixes (
call :dk_color2 %Blue% "Press [1] to Open Troubleshoot Page " %Gray% " Press [0] to Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))
) )
@ -2807,7 +2808,15 @@ set _sortIds=!_sortIds:PreInstallR_=Retail_!
:: https://learn.microsoft.com/office/troubleshoot/activation/reset-office-365-proplus-activation-state :: https://learn.microsoft.com/office/troubleshoot/activation/reset-office-365-proplus-activation-state
set _sidlist= set _sidlist=
for /f "tokens=* delims=" %%a in ('%psc% "$p = 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList'; Get-ChildItem $p | ForEach-Object { $pi = (Get-ItemProperty """"$p\$($_.PSChildName)"""").ProfileImagePath; if ($pi -like """"$Env:SystemDrive\Users\*"""" -and (Test-Path """"$pi\NTUSER.DAT"""") -and -not ($_ -match '\.bak$')) { Split-Path $_.PSPath -Leaf } }" %nul6%') do (if defined _sidlist (set _sidlist=!_sidlist! %%a) else (set _sidlist=%%a)) set failedload=
for /f "tokens=* delims=" %%a in ('%psc% "$p = 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList'; Get-ChildItem $p | ForEach-Object { $pi = (Get-ItemProperty """"$p\$($_.PSChildName)"""").ProfileImagePath; if ($_.PSChildName -match '^S-([^-\n]*-){5,}[^-\n]*$' -and (Test-Path """"$pi\NTUSER.DAT"""") -and -not ($_ -match '\.bak$')) { Split-Path $_.PSPath -Leaf } }" %nul6%') do (if defined _sidlist (set _sidlist=!_sidlist! %%a) else (set _sidlist=%%a))
:: Fallback method
if not defined _sidlist (
set failedload=1
for /f "delims=" %%a in ('%psc% "$explorerProc = Get-Process -Name explorer | Where-Object {$_.SessionId -eq (Get-Process -Id $pid).SessionId} | Select-Object -First 1; $sid = (gwmi -Query ('Select * From Win32_Process Where ProcessID=' + $explorerProc.Id)).GetOwnerSid().Sid; $sid" %nul6%') do (set _sidlist=%%a)
)
if not defined _sidlist ( if not defined _sidlist (
set error=1 set error=1
@ -2827,8 +2836,6 @@ call :dk_color %Gray% "Checking Total User Accounts [%counter%]"
:: Load the unloaded useraccounts registry :: Load the unloaded useraccounts registry
set loadedsids= set loadedsids=
set failedtoload=
set failedtounload=
for %%# in (%_sidlist%) do ( for %%# in (%_sidlist%) do (
reg query HKU\%%#\Software %nul% || ( reg query HKU\%%#\Software %nul% || (
for /f "skip=2 tokens=2*" %%a in ('"reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList\%%#" /v ProfileImagePath" %nul6%') do ( for /f "skip=2 tokens=2*" %%a in ('"reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList\%%#" /v ProfileImagePath" %nul6%') do (
@ -2836,7 +2843,7 @@ reg load HKU\%%# "%%b\NTUSER.DAT" %nul%
reg query HKU\%%#\Software %nul% && ( reg query HKU\%%#\Software %nul% && (
call set "loadedsids=%%loadedsids%% %%#" call set "loadedsids=%%loadedsids%% %%#"
) || ( ) || (
set failedtoload=1 set failedload=1
) )
) )
) )
@ -2898,13 +2905,19 @@ echo Clearing Office License Blocks [Successfully cleared from all %cou
:: Some retail products attempt to validate the license and may show a banner "There was a problem checking this device's license status." :: Some retail products attempt to validate the license and may show a banner "There was a problem checking this device's license status."
:: Resiliency registry entry can skip this check :: Resiliency registry entry can skip this check
set faileddef=
for /f "skip=2 tokens=2*" %%a in ('"reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList" /v Default" %nul6%') do call set "defdat=%%b"
if defined o16c2r if defined officeact ( if defined o16c2r if defined officeact (
reg load HKU\DEF_TEMP %SystemDrive%\Users\Default\NTUSER.DAT %nul% if exist "%defdat%\NTUSER.DAT" (
reg query HKU\DEF_TEMP %nul% || set failedtoload=1 reg load HKU\DEF_TEMP "%defdat%\NTUSER.DAT" %nul%
reg query HKU\DEF_TEMP %nul% || set faileddef=1
reg add HKU\DEF_TEMP\Software\Microsoft\Office\16.0\Common\Licensing\Resiliency /v "TimeOfLastHeartbeatFailure" /t REG_SZ /d "2040-01-01T00:00:00Z" /f %nul% reg add HKU\DEF_TEMP\Software\Microsoft\Office\16.0\Common\Licensing\Resiliency /v "TimeOfLastHeartbeatFailure" /t REG_SZ /d "2040-01-01T00:00:00Z" /f %nul%
reg unload HKU\DEF_TEMP %nul% reg unload HKU\DEF_TEMP %nul%
reg query HKU\DEF_TEMP %nul% && set failedtounload=1 reg query HKU\DEF_TEMP %nul% && set faileddef=1
) else (
set faileddef=1
)
for %%# in (%_sidlist%) do ( for %%# in (%_sidlist%) do (
reg delete HKU\%%#\Software\Microsoft\Office\16.0\Common\Licensing\Resiliency /f %nul% reg delete HKU\%%#\Software\Microsoft\Office\16.0\Common\Licensing\Resiliency /f %nul%
reg add HKU\%%#\Software\Microsoft\Office\16.0\Common\Licensing\Resiliency /v "TimeOfLastHeartbeatFailure" /t REG_SZ /d "2040-01-01T00:00:00Z" /f %nul% reg add HKU\%%#\Software\Microsoft\Office\16.0\Common\Licensing\Resiliency /v "TimeOfLastHeartbeatFailure" /t REG_SZ /d "2040-01-01T00:00:00Z" /f %nul%
@ -2918,19 +2931,15 @@ echo Adding Reg Keys to Skip License Check [Successfully added to all %counter
for %%# in (%loadedsids%) do ( for %%# in (%loadedsids%) do (
reg unload HKU\%%# %nul% reg unload HKU\%%# %nul%
reg query HKU\%%# %nul% && set failedtounload=1 reg query HKU\%%# %nul% && set failedload=1
) )
if defined failedtoload ( if defined failedload (
set error=1 call :dk_color %Gray% "Loading Unloading Registries [Failed for some user accounts]"
call :dk_color %Red% "Loading Unloaded Accounts Registry [Failed for some user accounts]"
call :dk_color %Blue% "Reboot your machine using the restart option and try again."
) )
if defined failedtounload ( if defined faileddef (
set error=1 call :dk_color %Gray% "Loading Unloading Registries [Failed for Default\NTUSER.DAT]"
call :dk_color %Red% "Unloading Loaded Account Registries [Failed for some user accounts]"
call :dk_color %Blue% "Reboot your machine using the restart option and try again."
) )
exit /b exit /b
@ -6336,12 +6345,12 @@ aaea0dc8-78e1-4343-9f25-b69b83dd1bce_D9GTG-NP7DV-T6JP3-B6B62-JB%f%89R__16_Projec
cbbba2c3-0ff5-4558-846a-043ef9d78559_F4DYN-89BP2-WQTWJ-GR8YC-CK%f%GJG__16_Excel2024Volume_-Excel2024Retail- cbbba2c3-0ff5-4558-846a-043ef9d78559_F4DYN-89BP2-WQTWJ-GR8YC-CK%f%GJG__16_Excel2024Volume_-Excel2024Retail-
bef3152a-8a04-40f2-a065-340c3f23516d_D2F8D-N3Q3B-J28PV-X27HD-RJ%f%WB9__16_Outlook2024Volume_-Outlook2024Retail- bef3152a-8a04-40f2-a065-340c3f23516d_D2F8D-N3Q3B-J28PV-X27HD-RJ%f%WB9__16_Outlook2024Volume_-Outlook2024Retail-
b63626a4-5f05-4ced-9639-31ba730a127e_CW94N-K6GJH-9CTXY-MG2VC-FY%f%CWP__16_PowerPoint2024Volume_-PowerPoint2024Retail- b63626a4-5f05-4ced-9639-31ba730a127e_CW94N-K6GJH-9CTXY-MG2VC-FY%f%CWP__16_PowerPoint2024Volume_-PowerPoint2024Retail-
f510af75-8ab7-4426-a236-1bfb95c34ff8_NBBBB-BBBBB-BBBBB-BBBH4-GX%f%3R4__16_ProjectPro2024Volume_-ProjectPro2024Retail- f510af75-8ab7-4426-a236-1bfb95c34ff8_FQQ23-N4YCY-73HQ3-FM9WC-76%f%HF4__16_ProjectPro2024Volume_-ProjectPro2024Retail-
9f144f27-2ac5-40b9-899d-898c2b8b4f81_PD3TT-NTHQQ-VC7CY-MFXK3-G8%f%7F8__16_ProjectStd2024Volume_-ProjectStd2024Retail- 9f144f27-2ac5-40b9-899d-898c2b8b4f81_PD3TT-NTHQQ-VC7CY-MFXK3-G8%f%7F8__16_ProjectStd2024Volume_-ProjectStd2024Retail-
8d368fc1-9470-4be2-8d66-90e836cbb051_NBBBB-BBBBB-BBBBB-BBBJD-VX%f%RPM__16_ProPlus2024Volume_-ProPlus2024Retail- 8d368fc1-9470-4be2-8d66-90e836cbb051_XJ2XN-FW8RK-P4HMP-DKDBV-GC%f%VGB__16_ProPlus2024Volume_-ProPlus2024Retail-
0002290a-2091-4324-9e53-3cfe28884cde_4NKHF-9HBQF-Q3B6C-7YV34-F6%f%4P3__16_SkypeforBusiness2024Volume 0002290a-2091-4324-9e53-3cfe28884cde_4NKHF-9HBQF-Q3B6C-7YV34-F6%f%4P3__16_SkypeforBusiness2024Volume
bbac904f-6a7e-418a-bb4b-24c85da06187_V28N4-JG22K-W66P8-VTMGK-H6%f%HGR__16_Standard2024Volume_-Home2024Retail-HomeBusiness2024Retail- bbac904f-6a7e-418a-bb4b-24c85da06187_V28N4-JG22K-W66P8-VTMGK-H6%f%HGR__16_Standard2024Volume_-Home2024Retail-HomeBusiness2024Retail-
fa187091-8246-47b1-964f-80a0b1e5d69a_NBBBB-BBBBB-BBBBB-BBBCW-6M%f%X6T__16_VisioPro2024Volume_-VisioPro2024Retail- fa187091-8246-47b1-964f-80a0b1e5d69a_B7TN8-FJ8V3-7QYCP-HQPMV-YY%f%89G__16_VisioPro2024Volume_-VisioPro2024Retail-
923fa470-aa71-4b8b-b35c-36b79bf9f44b_JMMVY-XFNQC-KK4HK-9H7R3-WQ%f%QTV__16_VisioStd2024Volume_-VisioStd2024Retail- 923fa470-aa71-4b8b-b35c-36b79bf9f44b_JMMVY-XFNQC-KK4HK-9H7R3-WQ%f%QTV__16_VisioStd2024Volume_-VisioStd2024Retail-
d0eded01-0881-4b37-9738-190400095098_MQ84N-7VYDM-FXV7C-6K7CC-VF%f%W9J__16_Word2024Volume_-Word2024Retail- d0eded01-0881-4b37-9738-190400095098_MQ84N-7VYDM-FXV7C-6K7CC-VF%f%W9J__16_Word2024Volume_-Word2024Retail-
) do ( ) do (
@ -9926,10 +9935,12 @@ for %%# in (
for /f "tokens=1-2 delims=_" %%A in ("%%~#") do ( for /f "tokens=1-2 delims=_" %%A in ("%%~#") do (
set supported= set supported=
if %winbuild% LSS 10240 (echo %%B | findstr /i "LTSC DevMain" %nul% || set supported=1) else (set supported=1) if %winbuild% LSS 10240 (echo %%B | findstr /i "LTSC DevMain" %nul% || set supported=1) else (set supported=1)
if %winbuild% GEQ 10240 (if defined ltsc19 echo %%B | findstr /i "LTSC\>" %nul% || set supported=) if %winbuild% GEQ 10240 (
if %winbuild% GEQ 10240 (if defined ltsc21 echo %%B | findstr /i "LTSC2021\>" %nul% || set supported=) if defined ltsc19 echo %%A | findstr /i "2019 VL" %nul% || set supported=
if %winbuild% GEQ 10240 (if defined ltsc24 echo %%B | findstr /i "LTSC2024\>" %nul% || set supported=) if defined ltsc21 echo %%A | findstr /i "2021 VL" %nul% || set supported=
if %winbuild% GEQ 10240 (if not defined ltscfound echo %%B | findstr /i "LTSC" %nul% && set supported=) if defined ltsc24 echo %%A | findstr /i "2024 VL" %nul% || set supported=
if not defined ltscfound echo %%B | findstr /i "LTSC" %nul% && set supported=
)
if defined supported ( if defined supported (
set /a counter+=1 set /a counter+=1
if !counter! LSS 10 ( if !counter! LSS 10 (
@ -10016,7 +10027,7 @@ call :oe_tempcleanup
echo: echo:
if defined fixes ( if defined fixes (
call :dk_color2 %Blue% "Press [1] To Open Troubleshoot Page " %Gray% " Press [0] To Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))
) )
@ -10099,13 +10110,15 @@ if exist "%_cfolder%\OfficeC2RClient.exe" (
set "_c2rCexe=%_cfolder%\OfficeC2RClient.exe" set "_c2rCexe=%_cfolder%\OfficeC2RClient.exe"
) )
echo %_AudienceData% | findstr /i "LTSC\>" %nul% && set ltsc19=LTSC set "audidata4=%_AudienceData:~-4%"
if /i "%audidata4%"=="LTSC" set ltsc19=LTSC
echo %_clversion% %_version% | findstr "16.0.103 16.0.104 16.0.105" %nul% && set ltsc19=LTSC echo %_clversion% %_version% | findstr "16.0.103 16.0.104 16.0.105" %nul% && set ltsc19=LTSC
echo %_AudienceData% | findstr /i "LTSC2021\>" %nul% && set ltsc21=LTSC2021 if /i "%audidata4%"=="2021" set ltsc21=LTSC2021
echo %_clversion% %_version% | findstr "16.0.14332" %nul% && set ltsc21=LTSC2021 echo %_clversion% %_version% | findstr "16.0.14332" %nul% && set ltsc21=LTSC2021
echo %_AudienceData% | findstr /i "LTSC2024\>" %nul% && set ltsc24=LTSC2024 if /i "%audidata4%"=="2024" set ltsc24=LTSC2024
:: LTSC 2024 build is not fixed yet :: LTSC 2024 build is not fixed yet
if not "%ltsc19%%ltsc21%%ltsc24%"=="" set ltscfound=1 if not "%ltsc19%%ltsc21%%ltsc24%"=="" set ltscfound=1
@ -10252,4 +10265,5 @@ if ($appIdsList.Count -gt 0) {
:getappnames: :getappnames:
::======================================================================================================================================== ::========================================================================================================================================
::
:: Leave empty line below :: Leave empty line below

View File

@ -1221,9 +1221,9 @@ call :dk_color2 %Red% "Checking Boot Mode [%safeboot_option
for /f "skip=2 tokens=2*" %%A in ('reg query "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Setup\State" /v ImageState') do (set imagestate=%%B) for /f "skip=2 tokens=2*" %%A in ('reg query "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Setup\State" /v ImageState') do (set imagestate=%%B)
if /i not "%imagestate%"=="IMAGE_STATE_COMPLETE" ( if /i not "%imagestate%"=="IMAGE_STATE_COMPLETE" (
set error=1 call :dk_color %Gray% "Checking Windows Setup State [%imagestate%]"
call :dk_color %Red% "Checking Windows Setup State [%imagestate%]"
echo "%imagestate%" | find /i "RESEAL" %nul% && ( echo "%imagestate%" | find /i "RESEAL" %nul% && (
set error=1
set showfix=1 set showfix=1
call :dk_color %Blue% "You need to run it in normal mode in case you are running it in Audit Mode." call :dk_color %Blue% "You need to run it in normal mode in case you are running it in Audit Mode."
) )
@ -1450,6 +1450,7 @@ for /f "delims=" %%a in ('%psc% "(Get-ScheduledTask -TaskName 'SvcRestartTask' -
echo !taskinfo! | find /i "Ready" %nul% || ( echo !taskinfo! | find /i "Ready" %nul% || (
reg delete "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SoftwareProtectionPlatform" /v "actionlist" /f %nul% reg delete "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SoftwareProtectionPlatform" /v "actionlist" /f %nul%
reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Schedule\TaskCache\Tree\Microsoft\Windows\SoftwareProtectionPlatform\SvcRestartTask" %nul% || set taskinfo=Removed reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Schedule\TaskCache\Tree\Microsoft\Windows\SoftwareProtectionPlatform\SvcRestartTask" %nul% || set taskinfo=Removed
if "!taskinfo!"=="" set "taskinfo=Not Found"
call :dk_color %Red% "Checking SvcRestartTask Status [!taskinfo!, System might deactivate later]" call :dk_color %Red% "Checking SvcRestartTask Status [!taskinfo!, System might deactivate later]"
) )
) )
@ -1592,7 +1593,7 @@ echo:
if %_unattended%==1 timeout /t 2 & exit /b if %_unattended%==1 timeout /t 2 & exit /b
if defined fixes ( if defined fixes (
call :dk_color2 %Blue% "Press [1] to Open Troubleshoot Page " %Gray% " Press [0] to Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))
) )

View File

@ -1375,9 +1375,9 @@ call :dk_color2 %Red% "Checking Boot Mode [%safeboot_option
for /f "skip=2 tokens=2*" %%A in ('reg query "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Setup\State" /v ImageState') do (set imagestate=%%B) for /f "skip=2 tokens=2*" %%A in ('reg query "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Setup\State" /v ImageState') do (set imagestate=%%B)
if /i not "%imagestate%"=="IMAGE_STATE_COMPLETE" ( if /i not "%imagestate%"=="IMAGE_STATE_COMPLETE" (
set error=1 call :dk_color %Gray% "Checking Windows Setup State [%imagestate%]"
call :dk_color %Red% "Checking Windows Setup State [%imagestate%]"
echo "%imagestate%" | find /i "RESEAL" %nul% && ( echo "%imagestate%" | find /i "RESEAL" %nul% && (
set error=1
set showfix=1 set showfix=1
call :dk_color %Blue% "You need to run it in normal mode in case you are running it in Audit Mode." call :dk_color %Blue% "You need to run it in normal mode in case you are running it in Audit Mode."
) )
@ -1604,6 +1604,7 @@ for /f "delims=" %%a in ('%psc% "(Get-ScheduledTask -TaskName 'SvcRestartTask' -
echo !taskinfo! | find /i "Ready" %nul% || ( echo !taskinfo! | find /i "Ready" %nul% || (
reg delete "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SoftwareProtectionPlatform" /v "actionlist" /f %nul% reg delete "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SoftwareProtectionPlatform" /v "actionlist" /f %nul%
reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Schedule\TaskCache\Tree\Microsoft\Windows\SoftwareProtectionPlatform\SvcRestartTask" %nul% || set taskinfo=Removed reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Schedule\TaskCache\Tree\Microsoft\Windows\SoftwareProtectionPlatform\SvcRestartTask" %nul% || set taskinfo=Removed
if "!taskinfo!"=="" set "taskinfo=Not Found"
call :dk_color %Red% "Checking SvcRestartTask Status [!taskinfo!, System might deactivate later]" call :dk_color %Red% "Checking SvcRestartTask Status [!taskinfo!, System might deactivate later]"
) )
) )
@ -1746,7 +1747,7 @@ echo:
if %_unattended%==1 timeout /t 2 & exit /b if %_unattended%==1 timeout /t 2 & exit /b
if defined fixes ( if defined fixes (
call :dk_color2 %Blue% "Press [1] to Open Troubleshoot Page " %Gray% " Press [0] to Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))
) )

View File

@ -1106,7 +1106,15 @@ set _sortIds=!_sortIds:PreInstallR_=Retail_!
:: https://learn.microsoft.com/office/troubleshoot/activation/reset-office-365-proplus-activation-state :: https://learn.microsoft.com/office/troubleshoot/activation/reset-office-365-proplus-activation-state
set _sidlist= set _sidlist=
for /f "tokens=* delims=" %%a in ('%psc% "$p = 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList'; Get-ChildItem $p | ForEach-Object { $pi = (Get-ItemProperty """"$p\$($_.PSChildName)"""").ProfileImagePath; if ($pi -like """"$Env:SystemDrive\Users\*"""" -and (Test-Path """"$pi\NTUSER.DAT"""") -and -not ($_ -match '\.bak$')) { Split-Path $_.PSPath -Leaf } }" %nul6%') do (if defined _sidlist (set _sidlist=!_sidlist! %%a) else (set _sidlist=%%a)) set failedload=
for /f "tokens=* delims=" %%a in ('%psc% "$p = 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList'; Get-ChildItem $p | ForEach-Object { $pi = (Get-ItemProperty """"$p\$($_.PSChildName)"""").ProfileImagePath; if ($_.PSChildName -match '^S-([^-\n]*-){5,}[^-\n]*$' -and (Test-Path """"$pi\NTUSER.DAT"""") -and -not ($_ -match '\.bak$')) { Split-Path $_.PSPath -Leaf } }" %nul6%') do (if defined _sidlist (set _sidlist=!_sidlist! %%a) else (set _sidlist=%%a))
:: Fallback method
if not defined _sidlist (
set failedload=1
for /f "delims=" %%a in ('%psc% "$explorerProc = Get-Process -Name explorer | Where-Object {$_.SessionId -eq (Get-Process -Id $pid).SessionId} | Select-Object -First 1; $sid = (gwmi -Query ('Select * From Win32_Process Where ProcessID=' + $explorerProc.Id)).GetOwnerSid().Sid; $sid" %nul6%') do (set _sidlist=%%a)
)
if not defined _sidlist ( if not defined _sidlist (
set error=1 set error=1
@ -1126,8 +1134,6 @@ call :dk_color %Gray% "Checking Total User Accounts [%counter%]"
:: Load the unloaded useraccounts registry :: Load the unloaded useraccounts registry
set loadedsids= set loadedsids=
set failedtoload=
set failedtounload=
for %%# in (%_sidlist%) do ( for %%# in (%_sidlist%) do (
reg query HKU\%%#\Software %nul% || ( reg query HKU\%%#\Software %nul% || (
for /f "skip=2 tokens=2*" %%a in ('"reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList\%%#" /v ProfileImagePath" %nul6%') do ( for /f "skip=2 tokens=2*" %%a in ('"reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList\%%#" /v ProfileImagePath" %nul6%') do (
@ -1135,7 +1141,7 @@ reg load HKU\%%# "%%b\NTUSER.DAT" %nul%
reg query HKU\%%#\Software %nul% && ( reg query HKU\%%#\Software %nul% && (
call set "loadedsids=%%loadedsids%% %%#" call set "loadedsids=%%loadedsids%% %%#"
) || ( ) || (
set failedtoload=1 set failedload=1
) )
) )
) )
@ -1197,13 +1203,19 @@ echo Clearing Office License Blocks [Successfully cleared from all %cou
:: Some retail products attempt to validate the license and may show a banner "There was a problem checking this device's license status." :: Some retail products attempt to validate the license and may show a banner "There was a problem checking this device's license status."
:: Resiliency registry entry can skip this check :: Resiliency registry entry can skip this check
set faileddef=
for /f "skip=2 tokens=2*" %%a in ('"reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList" /v Default" %nul6%') do call set "defdat=%%b"
if defined o16c2r if defined officeact ( if defined o16c2r if defined officeact (
reg load HKU\DEF_TEMP %SystemDrive%\Users\Default\NTUSER.DAT %nul% if exist "%defdat%\NTUSER.DAT" (
reg query HKU\DEF_TEMP %nul% || set failedtoload=1 reg load HKU\DEF_TEMP "%defdat%\NTUSER.DAT" %nul%
reg query HKU\DEF_TEMP %nul% || set faileddef=1
reg add HKU\DEF_TEMP\Software\Microsoft\Office\16.0\Common\Licensing\Resiliency /v "TimeOfLastHeartbeatFailure" /t REG_SZ /d "2040-01-01T00:00:00Z" /f %nul% reg add HKU\DEF_TEMP\Software\Microsoft\Office\16.0\Common\Licensing\Resiliency /v "TimeOfLastHeartbeatFailure" /t REG_SZ /d "2040-01-01T00:00:00Z" /f %nul%
reg unload HKU\DEF_TEMP %nul% reg unload HKU\DEF_TEMP %nul%
reg query HKU\DEF_TEMP %nul% && set failedtounload=1 reg query HKU\DEF_TEMP %nul% && set faileddef=1
) else (
set faileddef=1
)
for %%# in (%_sidlist%) do ( for %%# in (%_sidlist%) do (
reg delete HKU\%%#\Software\Microsoft\Office\16.0\Common\Licensing\Resiliency /f %nul% reg delete HKU\%%#\Software\Microsoft\Office\16.0\Common\Licensing\Resiliency /f %nul%
reg add HKU\%%#\Software\Microsoft\Office\16.0\Common\Licensing\Resiliency /v "TimeOfLastHeartbeatFailure" /t REG_SZ /d "2040-01-01T00:00:00Z" /f %nul% reg add HKU\%%#\Software\Microsoft\Office\16.0\Common\Licensing\Resiliency /v "TimeOfLastHeartbeatFailure" /t REG_SZ /d "2040-01-01T00:00:00Z" /f %nul%
@ -1217,19 +1229,15 @@ echo Adding Reg Keys to Skip License Check [Successfully added to all %counter
for %%# in (%loadedsids%) do ( for %%# in (%loadedsids%) do (
reg unload HKU\%%# %nul% reg unload HKU\%%# %nul%
reg query HKU\%%# %nul% && set failedtounload=1 reg query HKU\%%# %nul% && set failedload=1
) )
if defined failedtoload ( if defined failedload (
set error=1 call :dk_color %Gray% "Loading Unloading Registries [Failed for some user accounts]"
call :dk_color %Red% "Loading Unloaded Accounts Registry [Failed for some user accounts]"
call :dk_color %Blue% "Reboot your machine using the restart option and try again."
) )
if defined failedtounload ( if defined faileddef (
set error=1 call :dk_color %Gray% "Loading Unloading Registries [Failed for Default\NTUSER.DAT]"
call :dk_color %Red% "Unloading Loaded Account Registries [Failed for some user accounts]"
call :dk_color %Blue% "Reboot your machine using the restart option and try again."
) )
exit /b exit /b
@ -1673,9 +1681,9 @@ call :dk_color2 %Red% "Checking Boot Mode [%safeboot_option
for /f "skip=2 tokens=2*" %%A in ('reg query "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Setup\State" /v ImageState') do (set imagestate=%%B) for /f "skip=2 tokens=2*" %%A in ('reg query "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Setup\State" /v ImageState') do (set imagestate=%%B)
if /i not "%imagestate%"=="IMAGE_STATE_COMPLETE" ( if /i not "%imagestate%"=="IMAGE_STATE_COMPLETE" (
set error=1 call :dk_color %Gray% "Checking Windows Setup State [%imagestate%]"
call :dk_color %Red% "Checking Windows Setup State [%imagestate%]"
echo "%imagestate%" | find /i "RESEAL" %nul% && ( echo "%imagestate%" | find /i "RESEAL" %nul% && (
set error=1
set showfix=1 set showfix=1
call :dk_color %Blue% "You need to run it in normal mode in case you are running it in Audit Mode." call :dk_color %Blue% "You need to run it in normal mode in case you are running it in Audit Mode."
) )
@ -1902,6 +1910,7 @@ for /f "delims=" %%a in ('%psc% "(Get-ScheduledTask -TaskName 'SvcRestartTask' -
echo !taskinfo! | find /i "Ready" %nul% || ( echo !taskinfo! | find /i "Ready" %nul% || (
reg delete "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SoftwareProtectionPlatform" /v "actionlist" /f %nul% reg delete "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SoftwareProtectionPlatform" /v "actionlist" /f %nul%
reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Schedule\TaskCache\Tree\Microsoft\Windows\SoftwareProtectionPlatform\SvcRestartTask" %nul% || set taskinfo=Removed reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Schedule\TaskCache\Tree\Microsoft\Windows\SoftwareProtectionPlatform\SvcRestartTask" %nul% || set taskinfo=Removed
if "!taskinfo!"=="" set "taskinfo=Not Found"
call :dk_color %Red% "Checking SvcRestartTask Status [!taskinfo!, System might deactivate later]" call :dk_color %Red% "Checking SvcRestartTask Status [!taskinfo!, System might deactivate later]"
) )
) )
@ -2044,7 +2053,7 @@ echo:
if %_unattended%==1 timeout /t 2 & exit /b if %_unattended%==1 timeout /t 2 & exit /b
if defined fixes ( if defined fixes (
call :dk_color2 %Blue% "Press [1] to Open Troubleshoot Page " %Gray% " Press [0] to Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))
) )

View File

@ -1207,7 +1207,15 @@ exit /b
:: https://learn.microsoft.com/office/troubleshoot/activation/reset-office-365-proplus-activation-state :: https://learn.microsoft.com/office/troubleshoot/activation/reset-office-365-proplus-activation-state
set _sidlist= set _sidlist=
for /f "tokens=* delims=" %%a in ('%psc% "$p = 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList'; Get-ChildItem $p | ForEach-Object { $pi = (Get-ItemProperty """"$p\$($_.PSChildName)"""").ProfileImagePath; if ($pi -like """"$Env:SystemDrive\Users\*"""" -and (Test-Path """"$pi\NTUSER.DAT"""") -and -not ($_ -match '\.bak$')) { Split-Path $_.PSPath -Leaf } }" %nul6%') do (if defined _sidlist (set _sidlist=!_sidlist! %%a) else (set _sidlist=%%a)) set failedload=
for /f "tokens=* delims=" %%a in ('%psc% "$p = 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList'; Get-ChildItem $p | ForEach-Object { $pi = (Get-ItemProperty """"$p\$($_.PSChildName)"""").ProfileImagePath; if ($_.PSChildName -match '^S-([^-\n]*-){5,}[^-\n]*$' -and (Test-Path """"$pi\NTUSER.DAT"""") -and -not ($_ -match '\.bak$')) { Split-Path $_.PSPath -Leaf } }" %nul6%') do (if defined _sidlist (set _sidlist=!_sidlist! %%a) else (set _sidlist=%%a))
:: Fallback method
if not defined _sidlist (
set failedload=1
for /f "delims=" %%a in ('%psc% "$explorerProc = Get-Process -Name explorer | Where-Object {$_.SessionId -eq (Get-Process -Id $pid).SessionId} | Select-Object -First 1; $sid = (gwmi -Query ('Select * From Win32_Process Where ProcessID=' + $explorerProc.Id)).GetOwnerSid().Sid; $sid" %nul6%') do (set _sidlist=%%a)
)
if not defined _sidlist ( if not defined _sidlist (
set error=1 set error=1
@ -1227,8 +1235,6 @@ call :dk_color %Gray% "Checking Total User Accounts [%counter%]"
:: Load the unloaded useraccounts registry :: Load the unloaded useraccounts registry
set loadedsids= set loadedsids=
set failedtoload=
set failedtounload=
for %%# in (%_sidlist%) do ( for %%# in (%_sidlist%) do (
reg query HKU\%%#\Software %nul% || ( reg query HKU\%%#\Software %nul% || (
for /f "skip=2 tokens=2*" %%a in ('"reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList\%%#" /v ProfileImagePath" %nul6%') do ( for /f "skip=2 tokens=2*" %%a in ('"reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList\%%#" /v ProfileImagePath" %nul6%') do (
@ -1236,7 +1242,7 @@ reg load HKU\%%# "%%b\NTUSER.DAT" %nul%
reg query HKU\%%#\Software %nul% && ( reg query HKU\%%#\Software %nul% && (
call set "loadedsids=%%loadedsids%% %%#" call set "loadedsids=%%loadedsids%% %%#"
) || ( ) || (
set failedtoload=1 set failedload=1
) )
) )
) )
@ -1298,13 +1304,19 @@ echo Clearing Office License Blocks [Successfully cleared from all %cou
:: Some retail products attempt to validate the license and may show a banner "There was a problem checking this device's license status." :: Some retail products attempt to validate the license and may show a banner "There was a problem checking this device's license status."
:: Resiliency registry entry can skip this check :: Resiliency registry entry can skip this check
set faileddef=
for /f "skip=2 tokens=2*" %%a in ('"reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList" /v Default" %nul6%') do call set "defdat=%%b"
if defined o16c2r if defined officeact ( if defined o16c2r if defined officeact (
reg load HKU\DEF_TEMP %SystemDrive%\Users\Default\NTUSER.DAT %nul% if exist "%defdat%\NTUSER.DAT" (
reg query HKU\DEF_TEMP %nul% || set failedtoload=1 reg load HKU\DEF_TEMP "%defdat%\NTUSER.DAT" %nul%
reg query HKU\DEF_TEMP %nul% || set faileddef=1
reg add HKU\DEF_TEMP\Software\Microsoft\Office\16.0\Common\Licensing\Resiliency /v "TimeOfLastHeartbeatFailure" /t REG_SZ /d "2040-01-01T00:00:00Z" /f %nul% reg add HKU\DEF_TEMP\Software\Microsoft\Office\16.0\Common\Licensing\Resiliency /v "TimeOfLastHeartbeatFailure" /t REG_SZ /d "2040-01-01T00:00:00Z" /f %nul%
reg unload HKU\DEF_TEMP %nul% reg unload HKU\DEF_TEMP %nul%
reg query HKU\DEF_TEMP %nul% && set failedtounload=1 reg query HKU\DEF_TEMP %nul% && set faileddef=1
) else (
set faileddef=1
)
for %%# in (%_sidlist%) do ( for %%# in (%_sidlist%) do (
reg delete HKU\%%#\Software\Microsoft\Office\16.0\Common\Licensing\Resiliency /f %nul% reg delete HKU\%%#\Software\Microsoft\Office\16.0\Common\Licensing\Resiliency /f %nul%
reg add HKU\%%#\Software\Microsoft\Office\16.0\Common\Licensing\Resiliency /v "TimeOfLastHeartbeatFailure" /t REG_SZ /d "2040-01-01T00:00:00Z" /f %nul% reg add HKU\%%#\Software\Microsoft\Office\16.0\Common\Licensing\Resiliency /v "TimeOfLastHeartbeatFailure" /t REG_SZ /d "2040-01-01T00:00:00Z" /f %nul%
@ -1318,19 +1330,15 @@ echo Adding Reg Keys to Skip License Check [Successfully added to all %counter
for %%# in (%loadedsids%) do ( for %%# in (%loadedsids%) do (
reg unload HKU\%%# %nul% reg unload HKU\%%# %nul%
reg query HKU\%%# %nul% && set failedtounload=1 reg query HKU\%%# %nul% && set failedload=1
) )
if defined failedtoload ( if defined failedload (
set error=1 call :dk_color %Gray% "Loading Unloading Registries [Failed for some user accounts]"
call :dk_color %Red% "Loading Unloaded Accounts Registry [Failed for some user accounts]"
call :dk_color %Blue% "Reboot your machine using the restart option and try again."
) )
if defined failedtounload ( if defined faileddef (
set error=1 call :dk_color %Gray% "Loading Unloading Registries [Failed for Default\NTUSER.DAT]"
call :dk_color %Red% "Unloading Loaded Account Registries [Failed for some user accounts]"
call :dk_color %Blue% "Reboot your machine using the restart option and try again."
) )
exit /b exit /b
@ -2722,9 +2730,9 @@ call :dk_color2 %Red% "Checking Boot Mode [%safeboot_option
for /f "skip=2 tokens=2*" %%A in ('reg query "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Setup\State" /v ImageState') do (set imagestate=%%B) for /f "skip=2 tokens=2*" %%A in ('reg query "HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Setup\State" /v ImageState') do (set imagestate=%%B)
if /i not "%imagestate%"=="IMAGE_STATE_COMPLETE" ( if /i not "%imagestate%"=="IMAGE_STATE_COMPLETE" (
set error=1 call :dk_color %Gray% "Checking Windows Setup State [%imagestate%]"
call :dk_color %Red% "Checking Windows Setup State [%imagestate%]"
echo "%imagestate%" | find /i "RESEAL" %nul% && ( echo "%imagestate%" | find /i "RESEAL" %nul% && (
set error=1
set showfix=1 set showfix=1
call :dk_color %Blue% "You need to run it in normal mode in case you are running it in Audit Mode." call :dk_color %Blue% "You need to run it in normal mode in case you are running it in Audit Mode."
) )
@ -2951,6 +2959,7 @@ for /f "delims=" %%a in ('%psc% "(Get-ScheduledTask -TaskName 'SvcRestartTask' -
echo !taskinfo! | find /i "Ready" %nul% || ( echo !taskinfo! | find /i "Ready" %nul% || (
reg delete "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SoftwareProtectionPlatform" /v "actionlist" /f %nul% reg delete "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SoftwareProtectionPlatform" /v "actionlist" /f %nul%
reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Schedule\TaskCache\Tree\Microsoft\Windows\SoftwareProtectionPlatform\SvcRestartTask" %nul% || set taskinfo=Removed reg query "HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Schedule\TaskCache\Tree\Microsoft\Windows\SoftwareProtectionPlatform\SvcRestartTask" %nul% || set taskinfo=Removed
if "!taskinfo!"=="" set "taskinfo=Not Found"
call :dk_color %Red% "Checking SvcRestartTask Status [!taskinfo!, System might deactivate later]" call :dk_color %Red% "Checking SvcRestartTask Status [!taskinfo!, System might deactivate later]"
) )
) )
@ -3093,7 +3102,7 @@ echo:
if %_unattended%==1 timeout /t 2 & exit /b if %_unattended%==1 timeout /t 2 & exit /b
if defined fixes ( if defined fixes (
call :dk_color2 %Blue% "Press [1] to Open Troubleshoot Page " %Gray% " Press [0] to Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))
) )
@ -3481,12 +3490,12 @@ aaea0dc8-78e1-4343-9f25-b69b83dd1bce_D9GTG-NP7DV-T6JP3-B6B62-JB%f%89R__16_Projec
cbbba2c3-0ff5-4558-846a-043ef9d78559_F4DYN-89BP2-WQTWJ-GR8YC-CK%f%GJG__16_Excel2024Volume_-Excel2024Retail- cbbba2c3-0ff5-4558-846a-043ef9d78559_F4DYN-89BP2-WQTWJ-GR8YC-CK%f%GJG__16_Excel2024Volume_-Excel2024Retail-
bef3152a-8a04-40f2-a065-340c3f23516d_D2F8D-N3Q3B-J28PV-X27HD-RJ%f%WB9__16_Outlook2024Volume_-Outlook2024Retail- bef3152a-8a04-40f2-a065-340c3f23516d_D2F8D-N3Q3B-J28PV-X27HD-RJ%f%WB9__16_Outlook2024Volume_-Outlook2024Retail-
b63626a4-5f05-4ced-9639-31ba730a127e_CW94N-K6GJH-9CTXY-MG2VC-FY%f%CWP__16_PowerPoint2024Volume_-PowerPoint2024Retail- b63626a4-5f05-4ced-9639-31ba730a127e_CW94N-K6GJH-9CTXY-MG2VC-FY%f%CWP__16_PowerPoint2024Volume_-PowerPoint2024Retail-
f510af75-8ab7-4426-a236-1bfb95c34ff8_NBBBB-BBBBB-BBBBB-BBBH4-GX%f%3R4__16_ProjectPro2024Volume_-ProjectPro2024Retail- f510af75-8ab7-4426-a236-1bfb95c34ff8_FQQ23-N4YCY-73HQ3-FM9WC-76%f%HF4__16_ProjectPro2024Volume_-ProjectPro2024Retail-
9f144f27-2ac5-40b9-899d-898c2b8b4f81_PD3TT-NTHQQ-VC7CY-MFXK3-G8%f%7F8__16_ProjectStd2024Volume_-ProjectStd2024Retail- 9f144f27-2ac5-40b9-899d-898c2b8b4f81_PD3TT-NTHQQ-VC7CY-MFXK3-G8%f%7F8__16_ProjectStd2024Volume_-ProjectStd2024Retail-
8d368fc1-9470-4be2-8d66-90e836cbb051_NBBBB-BBBBB-BBBBB-BBBJD-VX%f%RPM__16_ProPlus2024Volume_-ProPlus2024Retail- 8d368fc1-9470-4be2-8d66-90e836cbb051_XJ2XN-FW8RK-P4HMP-DKDBV-GC%f%VGB__16_ProPlus2024Volume_-ProPlus2024Retail-
0002290a-2091-4324-9e53-3cfe28884cde_4NKHF-9HBQF-Q3B6C-7YV34-F6%f%4P3__16_SkypeforBusiness2024Volume 0002290a-2091-4324-9e53-3cfe28884cde_4NKHF-9HBQF-Q3B6C-7YV34-F6%f%4P3__16_SkypeforBusiness2024Volume
bbac904f-6a7e-418a-bb4b-24c85da06187_V28N4-JG22K-W66P8-VTMGK-H6%f%HGR__16_Standard2024Volume_-Home2024Retail-HomeBusiness2024Retail- bbac904f-6a7e-418a-bb4b-24c85da06187_V28N4-JG22K-W66P8-VTMGK-H6%f%HGR__16_Standard2024Volume_-Home2024Retail-HomeBusiness2024Retail-
fa187091-8246-47b1-964f-80a0b1e5d69a_NBBBB-BBBBB-BBBBB-BBBCW-6M%f%X6T__16_VisioPro2024Volume_-VisioPro2024Retail- fa187091-8246-47b1-964f-80a0b1e5d69a_B7TN8-FJ8V3-7QYCP-HQPMV-YY%f%89G__16_VisioPro2024Volume_-VisioPro2024Retail-
923fa470-aa71-4b8b-b35c-36b79bf9f44b_JMMVY-XFNQC-KK4HK-9H7R3-WQ%f%QTV__16_VisioStd2024Volume_-VisioStd2024Retail- 923fa470-aa71-4b8b-b35c-36b79bf9f44b_JMMVY-XFNQC-KK4HK-9H7R3-WQ%f%QTV__16_VisioStd2024Volume_-VisioStd2024Retail-
d0eded01-0881-4b37-9738-190400095098_MQ84N-7VYDM-FXV7C-6K7CC-VF%f%W9J__16_Word2024Volume_-Word2024Retail- d0eded01-0881-4b37-9738-190400095098_MQ84N-7VYDM-FXV7C-6K7CC-VF%f%W9J__16_Word2024Volume_-Word2024Retail-
) do ( ) do (

View File

@ -884,10 +884,12 @@ for %%# in (
for /f "tokens=1-2 delims=_" %%A in ("%%~#") do ( for /f "tokens=1-2 delims=_" %%A in ("%%~#") do (
set supported= set supported=
if %winbuild% LSS 10240 (echo %%B | findstr /i "LTSC DevMain" %nul% || set supported=1) else (set supported=1) if %winbuild% LSS 10240 (echo %%B | findstr /i "LTSC DevMain" %nul% || set supported=1) else (set supported=1)
if %winbuild% GEQ 10240 (if defined ltsc19 echo %%B | findstr /i "LTSC\>" %nul% || set supported=) if %winbuild% GEQ 10240 (
if %winbuild% GEQ 10240 (if defined ltsc21 echo %%B | findstr /i "LTSC2021\>" %nul% || set supported=) if defined ltsc19 echo %%A | findstr /i "2019 VL" %nul% || set supported=
if %winbuild% GEQ 10240 (if defined ltsc24 echo %%B | findstr /i "LTSC2024\>" %nul% || set supported=) if defined ltsc21 echo %%A | findstr /i "2021 VL" %nul% || set supported=
if %winbuild% GEQ 10240 (if not defined ltscfound echo %%B | findstr /i "LTSC" %nul% && set supported=) if defined ltsc24 echo %%A | findstr /i "2024 VL" %nul% || set supported=
if not defined ltscfound echo %%B | findstr /i "LTSC" %nul% && set supported=
)
if defined supported ( if defined supported (
set /a counter+=1 set /a counter+=1
if !counter! LSS 10 ( if !counter! LSS 10 (
@ -974,7 +976,7 @@ call :oe_tempcleanup
echo: echo:
if defined fixes ( if defined fixes (
call :dk_color2 %Blue% "Press [1] To Open Troubleshoot Page " %Gray% " Press [0] To Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))
) )
@ -1057,13 +1059,15 @@ if exist "%_cfolder%\OfficeC2RClient.exe" (
set "_c2rCexe=%_cfolder%\OfficeC2RClient.exe" set "_c2rCexe=%_cfolder%\OfficeC2RClient.exe"
) )
echo %_AudienceData% | findstr /i "LTSC\>" %nul% && set ltsc19=LTSC set "audidata4=%_AudienceData:~-4%"
if /i "%audidata4%"=="LTSC" set ltsc19=LTSC
echo %_clversion% %_version% | findstr "16.0.103 16.0.104 16.0.105" %nul% && set ltsc19=LTSC echo %_clversion% %_version% | findstr "16.0.103 16.0.104 16.0.105" %nul% && set ltsc19=LTSC
echo %_AudienceData% | findstr /i "LTSC2021\>" %nul% && set ltsc21=LTSC2021 if /i "%audidata4%"=="2021" set ltsc21=LTSC2021
echo %_clversion% %_version% | findstr "16.0.14332" %nul% && set ltsc21=LTSC2021 echo %_clversion% %_version% | findstr "16.0.14332" %nul% && set ltsc21=LTSC2021
echo %_AudienceData% | findstr /i "LTSC2024\>" %nul% && set ltsc24=LTSC2024 if /i "%audidata4%"=="2024" set ltsc24=LTSC2024
:: LTSC 2024 build is not fixed yet :: LTSC 2024 build is not fixed yet
if not "%ltsc19%%ltsc21%%ltsc24%"=="" set ltscfound=1 if not "%ltsc19%%ltsc21%%ltsc24%"=="" set ltscfound=1
@ -1320,7 +1324,7 @@ echo:
if %_unattended%==1 timeout /t 2 & exit /b if %_unattended%==1 timeout /t 2 & exit /b
if defined fixes ( if defined fixes (
call :dk_color2 %Blue% "Press [1] To Open Troubleshoot Page " %Gray% " Press [0] To Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))
) )

View File

@ -987,7 +987,7 @@ echo:
if %_unattended%==1 timeout /t 2 & exit /b if %_unattended%==1 timeout /t 2 & exit /b
if defined fixes ( if defined fixes (
call :dk_color2 %Blue% "Press [1] to Open Troubleshoot Page " %Gray% " Press [0] to Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))
) )

View File

@ -701,7 +701,7 @@ echo ______________________________________________________________
echo: echo:
if defined fixes ( if defined fixes (
call :dk_color2 %Blue% "Press [1] to Open Troubleshoot Page " %Gray% " Press [0] to Ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))
) )

View File

@ -1381,7 +1381,7 @@ $key.SetAccessControl($acl)
echo: echo:
if defined fixes ( if defined fixes (
call :dk_color2 %Blue% "Press [1] to open Troubleshoot page " %Gray% " Press [0] to ignore" call :dk_color2 %Blue% "Press [1] to Open Support Webpage " %Gray% " Press [0] to Ignore"
choice /C:10 /N choice /C:10 /N
if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#)) if !errorlevel!==1 (for %%# in (%fixes%) do (start %%#))
) )