April 19, 200521 yr Not really sure if this can be done. I Need to deploy the Security Update for Word 2002 KB887978 as a login batch file. This is what I have so far: @ECHO OFF:STARTIF EXIST C:\WINNT\Installer\kb887978.exe GOTO ENDCOPY G:\XXXXXXX\New\kb887978.exe "C:\WINNT\Installer\kb887978.exe" /-YSTART /r /w C:\WINNT\Installer\kb887978.exe ECHO :ENDIt needs to be copied from a network drive and saved/installed and bypassed the next time the user logins. But I have not had much success running this batch file. Any insight on this matter would be greatly appreciated. Peace.....
April 19, 200521 yr The script itself looks fine to me, HickoryShade. The only possible error I can think of at the moment is if this script gets run before the network drive G gets mapped.You only say that you are having trouble running this script. Could you be more specific? What kind of errors, if any, are you getting? Is the update file copying but not being run? Is it not being copied at all? Is the script not running on login like it is supposed to?
April 19, 200521 yr The copy command syntax is wrong. The /-Y command comes right after copy, not after the source and destination.
April 19, 200521 yr Author Thanks for your post.....The batch file copies the file over but it does not want to install the file. There is no visible sign that 1) an install is happening or 2) that it actually installed. The KB887978 does require some interaction from the user. Would this cause the batch file not to install the file? Peace...
April 19, 200521 yr I've tidied it a little bit, but the only problem I could see was the /r switch, I've never heard of it!@ECHO OFF:STARTIF EXIST C:\WINNT\Installer\kb887978.exe GOTO :EOFCOPY G:\XXXXXXX\New\kb887978.exe "C:\WINNT\Installer\"START "" /w C:\WINNT\Installer\kb887978.exeGOTO :EOFYou could also add switches to the start line, maybe something like:/q /r:i or /q:a /r:sThe former would install without prompts and restart if required, whereas the latter would install in silent mode and force a restart. Edited April 19, 200521 yr by Yzöwl
April 19, 200521 yr Author Thank you all....Especially to Yzöwl!! Your post was the way to go This is how it looks now: @ECHO OFF:STARTIF EXIST C:\WINNT\Installer\kb887978.exe GOTO :EOFCOPY G:\XXXXXXX\New\kb887978.exe "C:\WINNT\Installer\"START "" /w C:\WINNT\Installer\kb887978.exe /q:aGOTO :EOFPeace Out....
Create an account or sign in to comment