Compare commits
No commits in common. "9f244ddc179b3fd3479aebec58cbc26c1bebb78a" and "be867f6616e7408342c00346bcee49268b966778" have entirely different histories.
9f244ddc17
...
be867f6616
|
@ -219,14 +219,12 @@ for /f "delims=" %%a in ('%psc% "if ($PSVersionTable.PSEdition -ne 'Core') {$f=[
|
|||
|
||||
if /i not "%tstresult%"=="FullLanguage" (
|
||||
%eline%
|
||||
for /f "delims=" %%a in ('%psc% "$ExecutionContext.SessionState.LanguageMode" %nul6%') do (set tstresult2=%%a)
|
||||
echo Test 1 - %tstresult%
|
||||
echo Test 2 - !tstresult2!
|
||||
echo:
|
||||
echo: %tstresult%
|
||||
cmd /c "%psc% $ExecutionContext.SessionState.LanguageMode"
|
||||
|
||||
REM check LanguageMode
|
||||
|
||||
echo: !tstresult2! | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode"" | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
echo FullLanguage mode not found in PowerShell. Aborting...
|
||||
echo If you have applied restrictions on Powershell then undo those changes.
|
||||
echo:
|
||||
|
@ -256,13 +254,7 @@ goto dk_done
|
|||
REM check antivirus and other errors
|
||||
|
||||
echo PowerShell is not working properly. Aborting...
|
||||
|
||||
if /i "!tstresult2!"=="FullLanguage" (
|
||||
echo:
|
||||
echo Your antivirus software might be blocking the script, or PowerShell on your system might be corrupted.
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { $n += $i.displayName }; if ($n) { Write-Host ('Installed Antivirus - ' + ($n -join ', '))}"""
|
||||
)
|
||||
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { if ($i.displayName -notlike '*windows*') { $n += $i.displayName } }; if ($n) { Write-Host ('Installed 3rd party Antivirus might be blocking the script - ' + ($n -join ', ')) -ForegroundColor White -BackgroundColor Blue }"""
|
||||
echo:
|
||||
set fixes=%fixes% %mas%troubleshoot
|
||||
call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%troubleshoot"
|
||||
|
@ -396,16 +388,7 @@ if not defined terminal mode 76, 34
|
|||
if %winbuild% GEQ 10240 if not exist "%SystemRoot%\Servicing\Packages\Microsoft-Windows-Server*Edition~*.mum" if not exist "%SystemRoot%\Servicing\Packages\Microsoft-Windows-*EvalEdition~*.mum" set _hwidgo=1
|
||||
if %winbuild% GTR 14393 if exist "%SysPath%\spp\tokens\skus\EnterpriseSN\" set _hwidgo=
|
||||
if not defined _hwidgo set _tsforgego=1
|
||||
|
||||
set _ohookgo=1
|
||||
if %winbuild% GEQ 9200 (
|
||||
if %winbuild% LSS 10240 set _ohookgo=
|
||||
if %winbuild% GEQ 19041 if %winbuild% LEQ 19045 set _ohookgo=
|
||||
if exist "%SystemRoot%\Servicing\Packages\Microsoft-Windows-Server*Edition~*.mum" set _ohookgo=
|
||||
if exist "%SystemRoot%\Servicing\Packages\Microsoft-Windows-*EvalEdition~*.mum" set _ohookgo=
|
||||
if exist "%SystemRoot%\Servicing\Packages\Microsoft-Windows-EnterpriseS*dition~*.mum" set _ohookgo=
|
||||
)
|
||||
if not defined _ohookgo set _tsforgego=1
|
||||
|
||||
echo:
|
||||
echo:
|
||||
|
@ -2348,7 +2331,7 @@ call :dk_color %Red% "Checking Installed Office [Not Found]"
|
|||
|
||||
if defined ohub (
|
||||
echo:
|
||||
echo You only have the Office Dashboard app installed. You need to install the full version of Office.
|
||||
echo You only have the Office dashboard app installed, you need to install the full version of Office.
|
||||
)
|
||||
echo:
|
||||
call :dk_color %Blue% "Download and install Office from the below URL and then try again."
|
||||
|
@ -4654,7 +4637,7 @@ call :dk_color %Gray% "Checking Installed Office [Not Found]"
|
|||
|
||||
if defined ohub (
|
||||
echo:
|
||||
echo You only have the Office Dashboard app installed. You need to install the full version of Office.
|
||||
echo You have only Office dashboard app installed, you need to install full Office version.
|
||||
)
|
||||
call :dk_color %Blue% "Download and install Office from below URL and try again."
|
||||
if %_actwin%==0 set fixes=%fixes% %mas%genuine-installation-media
|
||||
|
@ -12083,7 +12066,7 @@ call :dk_color %Red% "Checking Installed Office [Not Found]"
|
|||
|
||||
if defined ohub (
|
||||
echo:
|
||||
echo You only have the Office Dashboard app installed. You need to install the full version of Office.
|
||||
echo You have only Office dashboard app installed, you need to install full Office version.
|
||||
)
|
||||
call :dk_color %Blue% "Download and install Office from below URL and try again."
|
||||
set fixes=%fixes% %mas%genuine-installation-media
|
||||
|
|
|
@ -241,14 +241,12 @@ for /f "delims=" %%a in ('%psc% "if ($PSVersionTable.PSEdition -ne 'Core') {$f=[
|
|||
|
||||
if /i not "%tstresult%"=="FullLanguage" (
|
||||
%eline%
|
||||
for /f "delims=" %%a in ('%psc% "$ExecutionContext.SessionState.LanguageMode" %nul6%') do (set tstresult2=%%a)
|
||||
echo Test 1 - %tstresult%
|
||||
echo Test 2 - !tstresult2!
|
||||
echo:
|
||||
echo: %tstresult%
|
||||
cmd /c "%psc% $ExecutionContext.SessionState.LanguageMode"
|
||||
|
||||
REM check LanguageMode
|
||||
|
||||
echo: !tstresult2! | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode"" | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
echo FullLanguage mode not found in PowerShell. Aborting...
|
||||
echo If you have applied restrictions on Powershell then undo those changes.
|
||||
echo:
|
||||
|
@ -278,13 +276,7 @@ goto dk_done
|
|||
REM check antivirus and other errors
|
||||
|
||||
echo PowerShell is not working properly. Aborting...
|
||||
|
||||
if /i "!tstresult2!"=="FullLanguage" (
|
||||
echo:
|
||||
echo Your antivirus software might be blocking the script, or PowerShell on your system might be corrupted.
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { $n += $i.displayName }; if ($n) { Write-Host ('Installed Antivirus - ' + ($n -join ', '))}"""
|
||||
)
|
||||
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { if ($i.displayName -notlike '*windows*') { $n += $i.displayName } }; if ($n) { Write-Host ('Installed 3rd party Antivirus might be blocking the script - ' + ($n -join ', ')) -ForegroundColor White -BackgroundColor Blue }"""
|
||||
echo:
|
||||
set fixes=%fixes% %mas%troubleshoot
|
||||
call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%troubleshoot"
|
||||
|
|
|
@ -244,14 +244,12 @@ for /f "delims=" %%a in ('%psc% "if ($PSVersionTable.PSEdition -ne 'Core') {$f=[
|
|||
|
||||
if /i not "%tstresult%"=="FullLanguage" (
|
||||
%eline%
|
||||
for /f "delims=" %%a in ('%psc% "$ExecutionContext.SessionState.LanguageMode" %nul6%') do (set tstresult2=%%a)
|
||||
echo Test 1 - %tstresult%
|
||||
echo Test 2 - !tstresult2!
|
||||
echo:
|
||||
echo: %tstresult%
|
||||
cmd /c "%psc% $ExecutionContext.SessionState.LanguageMode"
|
||||
|
||||
REM check LanguageMode
|
||||
|
||||
echo: !tstresult2! | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode"" | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
echo FullLanguage mode not found in PowerShell. Aborting...
|
||||
echo If you have applied restrictions on Powershell then undo those changes.
|
||||
echo:
|
||||
|
@ -281,13 +279,7 @@ goto dk_done
|
|||
REM check antivirus and other errors
|
||||
|
||||
echo PowerShell is not working properly. Aborting...
|
||||
|
||||
if /i "!tstresult2!"=="FullLanguage" (
|
||||
echo:
|
||||
echo Your antivirus software might be blocking the script, or PowerShell on your system might be corrupted.
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { $n += $i.displayName }; if ($n) { Write-Host ('Installed Antivirus - ' + ($n -join ', '))}"""
|
||||
)
|
||||
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { if ($i.displayName -notlike '*windows*') { $n += $i.displayName } }; if ($n) { Write-Host ('Installed 3rd party Antivirus might be blocking the script - ' + ($n -join ', ')) -ForegroundColor White -BackgroundColor Blue }"""
|
||||
echo:
|
||||
set fixes=%fixes% %mas%troubleshoot
|
||||
call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%troubleshoot"
|
||||
|
|
|
@ -249,14 +249,12 @@ for /f "delims=" %%a in ('%psc% "if ($PSVersionTable.PSEdition -ne 'Core') {$f=[
|
|||
|
||||
if /i not "%tstresult%"=="FullLanguage" (
|
||||
%eline%
|
||||
for /f "delims=" %%a in ('%psc% "$ExecutionContext.SessionState.LanguageMode" %nul6%') do (set tstresult2=%%a)
|
||||
echo Test 1 - %tstresult%
|
||||
echo Test 2 - !tstresult2!
|
||||
echo:
|
||||
echo: %tstresult%
|
||||
cmd /c "%psc% $ExecutionContext.SessionState.LanguageMode"
|
||||
|
||||
REM check LanguageMode
|
||||
|
||||
echo: !tstresult2! | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode"" | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
echo FullLanguage mode not found in PowerShell. Aborting...
|
||||
echo If you have applied restrictions on Powershell then undo those changes.
|
||||
echo:
|
||||
|
@ -286,13 +284,7 @@ goto dk_done
|
|||
REM check antivirus and other errors
|
||||
|
||||
echo PowerShell is not working properly. Aborting...
|
||||
|
||||
if /i "!tstresult2!"=="FullLanguage" (
|
||||
echo:
|
||||
echo Your antivirus software might be blocking the script, or PowerShell on your system might be corrupted.
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { $n += $i.displayName }; if ($n) { Write-Host ('Installed Antivirus - ' + ($n -join ', '))}"""
|
||||
)
|
||||
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { if ($i.displayName -notlike '*windows*') { $n += $i.displayName } }; if ($n) { Write-Host ('Installed 3rd party Antivirus might be blocking the script - ' + ($n -join ', ')) -ForegroundColor White -BackgroundColor Blue }"""
|
||||
echo:
|
||||
set fixes=%fixes% %mas%troubleshoot
|
||||
call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%troubleshoot"
|
||||
|
@ -539,7 +531,7 @@ call :dk_color %Red% "Checking Installed Office [Not Found]"
|
|||
|
||||
if defined ohub (
|
||||
echo:
|
||||
echo You only have the Office Dashboard app installed. You need to install the full version of Office.
|
||||
echo You only have the Office dashboard app installed, you need to install the full version of Office.
|
||||
)
|
||||
echo:
|
||||
call :dk_color %Blue% "Download and install Office from the below URL and then try again."
|
||||
|
|
|
@ -280,14 +280,12 @@ for /f "delims=" %%a in ('%psc% "if ($PSVersionTable.PSEdition -ne 'Core') {$f=[
|
|||
|
||||
if /i not "%tstresult%"=="FullLanguage" (
|
||||
%eline%
|
||||
for /f "delims=" %%a in ('%psc% "$ExecutionContext.SessionState.LanguageMode" %nul6%') do (set tstresult2=%%a)
|
||||
echo Test 1 - %tstresult%
|
||||
echo Test 2 - !tstresult2!
|
||||
echo:
|
||||
echo: %tstresult%
|
||||
cmd /c "%psc% $ExecutionContext.SessionState.LanguageMode"
|
||||
|
||||
REM check LanguageMode
|
||||
|
||||
echo: !tstresult2! | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode"" | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
echo FullLanguage mode not found in PowerShell. Aborting...
|
||||
echo If you have applied restrictions on Powershell then undo those changes.
|
||||
echo:
|
||||
|
@ -317,13 +315,7 @@ goto dk_done
|
|||
REM check antivirus and other errors
|
||||
|
||||
echo PowerShell is not working properly. Aborting...
|
||||
|
||||
if /i "!tstresult2!"=="FullLanguage" (
|
||||
echo:
|
||||
echo Your antivirus software might be blocking the script, or PowerShell on your system might be corrupted.
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { $n += $i.displayName }; if ($n) { Write-Host ('Installed Antivirus - ' + ($n -join ', '))}"""
|
||||
)
|
||||
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { if ($i.displayName -notlike '*windows*') { $n += $i.displayName } }; if ($n) { Write-Host ('Installed 3rd party Antivirus might be blocking the script - ' + ($n -join ', ')) -ForegroundColor White -BackgroundColor Blue }"""
|
||||
echo:
|
||||
set fixes=%fixes% %mas%troubleshoot
|
||||
call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%troubleshoot"
|
||||
|
@ -784,7 +776,7 @@ call :dk_color %Red% "Checking Installed Office [Not Found]"
|
|||
|
||||
if defined ohub (
|
||||
echo:
|
||||
echo You only have the Office Dashboard app installed. You need to install the full version of Office.
|
||||
echo You have only Office dashboard app installed, you need to install full Office version.
|
||||
)
|
||||
call :dk_color %Blue% "Download and install Office from below URL and try again."
|
||||
set fixes=%fixes% %mas%genuine-installation-media
|
||||
|
|
|
@ -298,14 +298,12 @@ for /f "delims=" %%a in ('%psc% "if ($PSVersionTable.PSEdition -ne 'Core') {$f=[
|
|||
|
||||
if /i not "%tstresult%"=="FullLanguage" (
|
||||
%eline%
|
||||
for /f "delims=" %%a in ('%psc% "$ExecutionContext.SessionState.LanguageMode" %nul6%') do (set tstresult2=%%a)
|
||||
echo Test 1 - %tstresult%
|
||||
echo Test 2 - !tstresult2!
|
||||
echo:
|
||||
echo: %tstresult%
|
||||
cmd /c "%psc% $ExecutionContext.SessionState.LanguageMode"
|
||||
|
||||
REM check LanguageMode
|
||||
|
||||
echo: !tstresult2! | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode"" | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
echo FullLanguage mode not found in PowerShell. Aborting...
|
||||
echo If you have applied restrictions on Powershell then undo those changes.
|
||||
echo:
|
||||
|
@ -335,13 +333,7 @@ goto dk_done
|
|||
REM check antivirus and other errors
|
||||
|
||||
echo PowerShell is not working properly. Aborting...
|
||||
|
||||
if /i "!tstresult2!"=="FullLanguage" (
|
||||
echo:
|
||||
echo Your antivirus software might be blocking the script, or PowerShell on your system might be corrupted.
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { $n += $i.displayName }; if ($n) { Write-Host ('Installed Antivirus - ' + ($n -join ', '))}"""
|
||||
)
|
||||
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { if ($i.displayName -notlike '*windows*') { $n += $i.displayName } }; if ($n) { Write-Host ('Installed 3rd party Antivirus might be blocking the script - ' + ($n -join ', ')) -ForegroundColor White -BackgroundColor Blue }"""
|
||||
echo:
|
||||
set fixes=%fixes% %mas%troubleshoot
|
||||
call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%troubleshoot"
|
||||
|
@ -1054,7 +1046,7 @@ call :dk_color %Gray% "Checking Installed Office [Not Found]"
|
|||
|
||||
if defined ohub (
|
||||
echo:
|
||||
echo You only have the Office Dashboard app installed. You need to install the full version of Office.
|
||||
echo You have only Office dashboard app installed, you need to install full Office version.
|
||||
)
|
||||
call :dk_color %Blue% "Download and install Office from below URL and try again."
|
||||
if %_actwin%==0 set fixes=%fixes% %mas%genuine-installation-media
|
||||
|
|
|
@ -194,14 +194,12 @@ for /f "delims=" %%a in ('%psc% "if ($PSVersionTable.PSEdition -ne 'Core') {$f=[
|
|||
|
||||
if /i not "%tstresult%"=="FullLanguage" (
|
||||
%eline%
|
||||
for /f "delims=" %%a in ('%psc% "$ExecutionContext.SessionState.LanguageMode" %nul6%') do (set tstresult2=%%a)
|
||||
echo Test 1 - %tstresult%
|
||||
echo Test 2 - !tstresult2!
|
||||
echo:
|
||||
echo: %tstresult%
|
||||
cmd /c "%psc% $ExecutionContext.SessionState.LanguageMode"
|
||||
|
||||
REM check LanguageMode
|
||||
|
||||
echo: !tstresult2! | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode"" | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
echo FullLanguage mode not found in PowerShell. Aborting...
|
||||
echo If you have applied restrictions on Powershell then undo those changes.
|
||||
echo:
|
||||
|
@ -231,13 +229,7 @@ goto dk_done
|
|||
REM check antivirus and other errors
|
||||
|
||||
echo PowerShell is not working properly. Aborting...
|
||||
|
||||
if /i "!tstresult2!"=="FullLanguage" (
|
||||
echo:
|
||||
echo Your antivirus software might be blocking the script, or PowerShell on your system might be corrupted.
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { $n += $i.displayName }; if ($n) { Write-Host ('Installed Antivirus - ' + ($n -join ', '))}"""
|
||||
)
|
||||
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { if ($i.displayName -notlike '*windows*') { $n += $i.displayName } }; if ($n) { Write-Host ('Installed 3rd party Antivirus might be blocking the script - ' + ($n -join ', ')) -ForegroundColor White -BackgroundColor Blue }"""
|
||||
echo:
|
||||
set fixes=%fixes% %mas%troubleshoot
|
||||
call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%troubleshoot"
|
||||
|
|
|
@ -199,14 +199,12 @@ for /f "delims=" %%a in ('%psc% "if ($PSVersionTable.PSEdition -ne 'Core') {$f=[
|
|||
|
||||
if /i not "%tstresult%"=="FullLanguage" (
|
||||
%eline%
|
||||
for /f "delims=" %%a in ('%psc% "$ExecutionContext.SessionState.LanguageMode" %nul6%') do (set tstresult2=%%a)
|
||||
echo Test 1 - %tstresult%
|
||||
echo Test 2 - !tstresult2!
|
||||
echo:
|
||||
echo: %tstresult%
|
||||
cmd /c "%psc% $ExecutionContext.SessionState.LanguageMode"
|
||||
|
||||
REM check LanguageMode
|
||||
|
||||
echo: !tstresult2! | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode"" | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
echo FullLanguage mode not found in PowerShell. Aborting...
|
||||
echo If you have applied restrictions on Powershell then undo those changes.
|
||||
echo:
|
||||
|
@ -236,13 +234,7 @@ goto dk_done
|
|||
REM check antivirus and other errors
|
||||
|
||||
echo PowerShell is not working properly. Aborting...
|
||||
|
||||
if /i "!tstresult2!"=="FullLanguage" (
|
||||
echo:
|
||||
echo Your antivirus software might be blocking the script, or PowerShell on your system might be corrupted.
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { $n += $i.displayName }; if ($n) { Write-Host ('Installed Antivirus - ' + ($n -join ', '))}"""
|
||||
)
|
||||
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { if ($i.displayName -notlike '*windows*') { $n += $i.displayName } }; if ($n) { Write-Host ('Installed 3rd party Antivirus might be blocking the script - ' + ($n -join ', ')) -ForegroundColor White -BackgroundColor Blue }"""
|
||||
echo:
|
||||
set fixes=%fixes% %mas%troubleshoot
|
||||
call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%troubleshoot"
|
||||
|
|
|
@ -210,14 +210,12 @@ for /f "delims=" %%a in ('%psc% "if ($PSVersionTable.PSEdition -ne 'Core') {$f=[
|
|||
|
||||
if /i not "%tstresult%"=="FullLanguage" (
|
||||
%eline%
|
||||
for /f "delims=" %%a in ('%psc% "$ExecutionContext.SessionState.LanguageMode" %nul6%') do (set tstresult2=%%a)
|
||||
echo Test 1 - %tstresult%
|
||||
echo Test 2 - !tstresult2!
|
||||
echo:
|
||||
echo: %tstresult%
|
||||
cmd /c "%psc% $ExecutionContext.SessionState.LanguageMode"
|
||||
|
||||
REM check LanguageMode
|
||||
|
||||
echo: !tstresult2! | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode"" | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
echo FullLanguage mode not found in PowerShell. Aborting...
|
||||
echo If you have applied restrictions on Powershell then undo those changes.
|
||||
echo:
|
||||
|
@ -247,13 +245,7 @@ goto done2
|
|||
REM check antivirus and other errors
|
||||
|
||||
echo PowerShell is not working properly. Aborting...
|
||||
|
||||
if /i "!tstresult2!"=="FullLanguage" (
|
||||
echo:
|
||||
echo Your antivirus software might be blocking the script, or PowerShell on your system might be corrupted.
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { $n += $i.displayName }; if ($n) { Write-Host ('Installed Antivirus - ' + ($n -join ', '))}"""
|
||||
)
|
||||
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { if ($i.displayName -notlike '*windows*') { $n += $i.displayName } }; if ($n) { Write-Host ('Installed 3rd party Antivirus might be blocking the script - ' + ($n -join ', ')) -ForegroundColor White -BackgroundColor Blue }"""
|
||||
echo:
|
||||
set fixes=%fixes% %mas%troubleshoot
|
||||
call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%troubleshoot"
|
||||
|
|
|
@ -211,14 +211,12 @@ for /f "delims=" %%a in ('%psc% "if ($PSVersionTable.PSEdition -ne 'Core') {$f=[
|
|||
|
||||
if /i not "%tstresult%"=="FullLanguage" (
|
||||
%eline%
|
||||
for /f "delims=" %%a in ('%psc% "$ExecutionContext.SessionState.LanguageMode" %nul6%') do (set tstresult2=%%a)
|
||||
echo Test 1 - %tstresult%
|
||||
echo Test 2 - !tstresult2!
|
||||
echo:
|
||||
echo: %tstresult%
|
||||
cmd /c "%psc% $ExecutionContext.SessionState.LanguageMode"
|
||||
|
||||
REM check LanguageMode
|
||||
|
||||
echo: !tstresult2! | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
cmd /c "%psc% "$ExecutionContext.SessionState.LanguageMode"" | findstr /i "ConstrainedLanguage RestrictedLanguage NoLanguage" %nul1% && (
|
||||
echo FullLanguage mode not found in PowerShell. Aborting...
|
||||
echo If you have applied restrictions on Powershell then undo those changes.
|
||||
echo:
|
||||
|
@ -248,13 +246,7 @@ goto dk_done
|
|||
REM check antivirus and other errors
|
||||
|
||||
echo PowerShell is not working properly. Aborting...
|
||||
|
||||
if /i "!tstresult2!"=="FullLanguage" (
|
||||
echo:
|
||||
echo Your antivirus software might be blocking the script, or PowerShell on your system might be corrupted.
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { $n += $i.displayName }; if ($n) { Write-Host ('Installed Antivirus - ' + ($n -join ', '))}"""
|
||||
)
|
||||
|
||||
cmd /c "%psc% ""$av = Get-WmiObject -Namespace root\SecurityCenter2 -Class AntiVirusProduct; $n = @(); foreach ($i in $av) { if ($i.displayName -notlike '*windows*') { $n += $i.displayName } }; if ($n) { Write-Host ('Installed 3rd party Antivirus might be blocking the script - ' + ($n -join ', ')) -ForegroundColor White -BackgroundColor Blue }"""
|
||||
echo:
|
||||
set fixes=%fixes% %mas%troubleshoot
|
||||
call :dk_color2 %Blue% "Check this webpage for help - " %_Yellow% " %mas%troubleshoot"
|
||||
|
|
Loading…
Reference in New Issue