Quantcast
Channel: The Official Scripting Guys Forum! forum
Viewing all articles
Browse latest Browse all 15028

batch file will not run properly help please!

$
0
0

I am trying to create a windows batch script that will allow me to deploy preparation updates for Windows 7 64 bit but the script will not launch properly. I have all of the files inside of the same folder and I am attempting to extract the files then install them through dism when I launch it normally the files extract but dism does not launch correctly, when I run as administrator the files will not extract and dism exits with code 2. What am I doing wrong?

expand -F:* .\Windows6.1-KB3135445-x64.msu .\
timeout 2
DISM.exe /online /Add-Package /PackagePath:.\Windows6.1-KB3135445-x64.cab
expand -F:* .\Windows6.1-KB3050265-x64.msu .\
timeout 2
DISM.exe /online /Add-Package /PackagePath:.\Windows6.1-KB3050265-x64.cab
expand -F:* .\Windows6.1-KB3065987-v2-x64.msu .\
timeout 2
DISM.exe /online /Add-Package /PackagePath:.\Windows6.1-KB3065987-v2-x64.cab
expand -F:* .\Windows6.1-KB3102810-x64.msu .\
timeout 2
DISM.exe /online /Add-Package /PackagePath:.\Windows6.1-KB3102810-x64.cab
expand -F:* .\Windows6.1-KB3138612-x64.msu .\
timeout 2
DISM.exe /online /Add-Package /PackagePath:.\Windows6.1-KB3138612-x64.cab
expand -F:* .\Windows6.1-KB3161608-x64.msu .\
timeout 2
DISM.exe /online /Add-Package /PackagePath:.\Windows6.1-KB3161608-x64.cab
expand -F:* .\Windows6.1-KB3161664-x64.msu .\
timeout 2
DISM.exe /online /Add-Package /PackagePath:.\Windows6.1-KB3161664-x64.cab
pause

Viewing all articles
Browse latest Browse all 15028

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>