From 7b33df167753d0488b3247259ca678ad3c969707 Mon Sep 17 00:00:00 2001 From: Andreas Lindemark <andreas.lindemark@liu.se> Date: Sat, 15 Aug 2020 15:47:20 +0200 Subject: [PATCH] Added variable form DISM, since it sometimes wasn't found. Also added verification check that DISM exists. --- Windows/Install_dotNET_FrameWork_3.5.cmd | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Windows/Install_dotNET_FrameWork_3.5.cmd b/Windows/Install_dotNET_FrameWork_3.5.cmd index d9b8668..328031c 100644 --- a/Windows/Install_dotNET_FrameWork_3.5.cmd +++ b/Windows/Install_dotNET_FrameWork_3.5.cmd @@ -1,15 +1,20 @@ : Specify path to \sources\sxs (for the right version of Windows 10) SET PATH="%1" +SET DISM="C:\WINDOWS\system32\DISM" + : Check that \sources\sxs exist IF NOT EXIST %PATH% GOTO :FAILED +: Check that DISM exist +IF NOT EXIST %DISM% GOTO :FAILED + : Check that \sources\sxs\*netfx3* and \sources\sxs\*NetFx3* exist IF NOT EXIST %PATH%\*netfx3* GOTO :FAILED IF NOT EXIST %PATH%\*NetFx3* GOTO :FAILED : Install .NET Framework 3.5 (incl. 2.0 and 3.0) -DISM /Online /Enable-Feature /FeatureName:NetFx3 /All /LimitAccess /Source:%PATH% +%DISM% /Online /Enable-Feature /FeatureName:NetFx3 /All /LimitAccess /Source:%PATH% GOTO :END :FAILED -- GitLab