Oh sorry. I misunderstood your mistake.
Try this. I put quotes around the log path to see if that was the problem.
Source: http://www.itninja.com/question/ie-10-silent-install-with-updatesoption explicitlyDim objFSO : set objFSO = CreateObject("Scripting.FileSystemObject")Dim objShell : set objShell = CreateObject("WScript.Shell")Dim objEnv : 设置 objEnv = objShell.Environment("Process")objEnv("SEE_MASK_NOZONECHECKS") = 1昏暗的 strScriptPath: strScriptPath = objFSO.GetParentFolderName(Wscript.ScriptFullName)Dim strLogFolder : strLogFolder = "U:\"Dim LogFile :设置 LogFile = objFSO.OpenTextFile(strLogFolder & "Microsoft_Internet_Explorer_10_VBscript.log", 8, True)Dim returns, KBname'Determine OS bit level'------------------------------------------------ -------------------------------------------------- ------------------Mute OSBitLevelIf GetObject("winmgmts:root\cimv2:Win32_Processor='cpu0'").AddressWidth = 32 ThenOS bit level = 32ElseIf GetObject("winmgmts:root\cimv2:Win32_Processor='cpu0'").AddressWidth = 64 然后OS bit level = 64In the case ofLogFile.WriteLine vbCrLf & String(117, "-") & vbCrLf'64-bit installation'------------------------------------------------ -------------------------------------------------- ------------------If OSBitLevel = 64 then'Install 64-bit patch for KB2670838 (graphics and image bug fixes)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(Now & "- Install update KB2670838_x64 to resolve graphics and imaging issues...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2670838-x64.msu /quiet /norestart /log:""" & strLogFolder & "KB2670838_x64.log""",0,True)result("KB2670838_x64")'Installer 64-bit patch til KB2729094 (Segoe font fix)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(now & "- Installing update KB2729094_x64 for Segoe font fix...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2729094-v2-x64.msu /quiet /norestart /log:""" & strLogFolder & "KB2729094_x64.log""",0,真的)result("KB2729094_x64")'Install 64-bit patch of KB2731771 (local/UTC time conversion)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(Now & "- Installing update KB2731771_x64 to fix local/UTC time conversion...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2731771-x64.msu /quiet /norestart /log:""" & strLogFolder & "KB2731771_x64.log""",0,True)result("KB2731771_x64")'Install the 64-bit patch for KB2533623 (Insecure Library Fixes)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(now & "- Installing update KB2533623_x64 to fix unsafe libraries...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2533623-x64.msu /quiet /norestart /log:""" & strLogFolder & "KB2533623_x64.log""",0,True)result("KB2533623_x64")'Install the 64-bit patch for KB2786081 (IE credential storage fix)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(now & "- Installing update KB2786081_x64 to fix IE credential storage...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2786081-x64.msu /quiet /norestart /log:""" & strLogFolder & "KB2786081_x64.log""",0,True)result("KB2786081_x64")'Installer 64-bit versions af Internet Explorer 10 (including 32-bit versions)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(Now & "-Installing 64-bit Internet Explorer 10...")LogFile.WriteLine(Now & " - Installationslog: " & strLogFolder & "Microsoft_IE_10.log")'Factory Installer: Return = objShell.Run(strScriptPath & "\IE10-Windows6.1-x64-en-us.exe /quiet /update-no /closeprograms /norestart /log:C:\Windows\Logs\", 0 , virkelig)If objFSO.FolderExists("C:\Windows\SysNative") Then'Run non-redirected to 64-bit DISMReturn = objShell.Run("C:\Windows\SysNative\dism.exe /online /add-package /packagepath:" & strScriptPath & "\IE10_x64\IE-Win7.CAB /quiet /norestart /logpath:""" & strLogFolder & "Microsoft_IE_10.log""",0,True)Other thingsReturn = objShell.Run("dism.exe /online /add-package /packagepath:" & strScriptPath & "\IE10_x64\IE-Win7.CAB /quiet /norestart /logpath:""" & strLogFolder & "Microsoft_IE_10.log" "",0,真)In the case ofif return = 3010 thenLogFile.WriteLine(now & "- WARNING: The installation of Internet Explorer 10 was completed successfully, but a required restart was suppressed!")WScript.exit(0)ElseIf returns <> 0 thenLogFile.WriteLine(Now & " - ERROR: Internet Explorer 10 installation failed, ERROR: " & RETURN)Other thingsLogFile.WriteLine(Now & "- The installation of Internet Explorer 10 has completed successfully.")In the case of'32 bit installation'------------------------------------------------ -------------------------------------------------- ------------------ElseIf OSBitLevel = 32 Then'Install the 32-bit patch for KB2670838 (graphics and image bug fixes)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(Now & "- Install update KB2670838_x86 to resolve graphics and imaging issues...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2670838-x86.msu /quiet /norestart /log:""" & strLogFolder & "KB2670838_x86.log""",0,True)result("KB2670838_x86")'Installer 32-bit patch til KB2729094 (Segoe font fix)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(now & "- Installing update KB2729094_x86 for Segoe font fix...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2729094-v2-x86.msu /quiet /norestart /log:""" & strLogFolder & "KB2729094_x86.log""",0,真的)result("KB2729094_x86")'Install 32-bit patch of KB2731771 (local/UTC time conversion)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(Now & "- Installing update KB2731771_x86 to fix local/UTC time conversion...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2731771-x86.msu /quiet /norestart /log:""" & strLogFolder & "KB2731771_x86.log""",0,True)result("KB2731771_x86")'Install the 32-bit patch for KB2533623 (Insecure Library Fixes)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(now & "- Installing update KB2533623_x86 to fix unsafe libraries...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2533623-x86.msu /quiet /norestart /log:""" & strLogFolder & "KB2533623_x86.log""",0,True)result("KB2533623_x86")'Install 32-bit patch for KB2786081 (IE storage of credentials)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(now & "- Installing update KB2786081_x86 to fix IE credential storage...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2786081-x86.msu /quiet /norestart /log:""" & strLogFolder & "KB2786081_x86.log""",0,True)result("KB2786081_x86")'Installer 32-bit Internet Explorer 10'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(Now & "- Installing Internet Explorer 10...")LogFile.WriteLine(Now & " - Installationslog: " & strLogFolder & "Microsoft_IE_10.log")'Factory Installer: Return = objShell.Run(strScriptPath & "\IE10-Windows6.1-x86-en-us.exe /quiet /update-no /closeprograms /norestart /log:C:\Windows\Logs\", 0 , virkelig)Return = objShell.Run("dism.exe /online /add-package /packagepath:" & strScriptPath & "\IE10_x86\IE-Win7.CAB /quiet /norestart /logpath:""" & strLogFolder & "Microsoft_IE_10.log" "",0,真)if return = 3010 thenLogFile.WriteLine(now & "- WARNING: The installation of Internet Explorer 10 was completed successfully, but a required restart was suppressed!")WScript.exit(0)ElseIf returns <> 0 thenLogFile.WriteLine(Now & " - ERROR: Internet Explorer 10 installation failed, ERROR: " & RETURN)Other thingsLogFile.WriteLine(Now & "- The installation of Internet Explorer 10 has completed successfully.")In the case ofIn the case oflogfile.close'Work'------------------------------------------------ -------------------------------------------------- ------------------function result (name of the knowledge base)select case returnSag 9009LogFile.WriteLine(Now & " - Warning: " & KBname & " is already installed; skipping installation.")Sag 2359302LogFile.WriteLine(Now & " - Warning: " & KBname & " is already installed; skipping installation.")Sag-2145124329LogFile.WriteLine(Now & " - Warning: " & KBname & " is not required for this system; installation skipped.")Other mattersLogFile.WriteLine(now & " - installation " & KBname & " completed, return code: " & RETURN)exit selectionexit function
opens in a new window
If that doesn't work, we can try per-install logging without explicit and write the return code to the main log.
Source: http://www.itninja.com/question/ie-10-silent-install-with-updatesoption explicitlyDim objFSO : set objFSO = CreateObject("Scripting.FileSystemObject")Dim objShell : set objShell = CreateObject("WScript.Shell")Dim objEnv : 设置 objEnv = objShell.Environment("Process")objEnv("SEE_MASK_NOZONECHECKS") = 1昏暗的 strScriptPath: strScriptPath = objFSO.GetParentFolderName(Wscript.ScriptFullName)Dim strLogFolder : strLogFolder = "U:\"Dim LogFile :设置 LogFile = objFSO.OpenTextFile(strLogFolder & "Microsoft_Internet_Explorer_10_VBscript.log", 8, True)Dim returns, KBname'Determine OS bit level'------------------------------------------------ -------------------------------------------------- ------------------Mute OSBitLevelIf GetObject("winmgmts:root\cimv2:Win32_Processor='cpu0'").AddressWidth = 32 ThenOS bit level = 32ElseIf GetObject("winmgmts:root\cimv2:Win32_Processor='cpu0'").AddressWidth = 64 然后OS bit level = 64In the case ofLogFile.WriteLine vbCrLf & String(117, "-") & vbCrLf'64-bit installation'------------------------------------------------ -------------------------------------------------- ------------------If OSBitLevel = 64 then'Install 64-bit patch for KB2670838 (graphics and image bug fixes)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(Now & "- Install update KB2670838_x64 to resolve graphics and imaging issues...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2670838-x64.msu /quiet /norestart",0,True)result("KB2670838_x64")'Installer 64-bit patch til KB2729094 (Segoe font fix)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(now & "- Installing update KB2729094_x64 for Segoe font fix...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2729094-v2-x64.msu /quiet /norestart",0,True)result("KB2729094_x64")'Install 64-bit patch of KB2731771 (local/UTC time conversion)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(Now & "- Installing update KB2731771_x64 to fix local/UTC time conversion...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2731771-x64.msu /quiet /norestart",0,True)result("KB2731771_x64")'Install the 64-bit patch for KB2533623 (Insecure Library Fixes)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(now & "- Installing update KB2533623_x64 to fix unsafe libraries...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2533623-x64.msu /quiet /norestart",0,True)result("KB2533623_x64")'Install the 64-bit patch for KB2786081 (IE credential storage fix)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(now & "- Installing update KB2786081_x64 to fix IE credential storage...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2786081-x64.msu /quiet /norestart",0,True)result("KB2786081_x64")'Installer 64-bit versions af Internet Explorer 10 (including 32-bit versions)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(Now & "-Installing 64-bit Internet Explorer 10...")LogFile.WriteLine(Now & " - Installationslog: " & strLogFolder & "Microsoft_IE_10.log")'Factory Installer: Return = objShell.Run(strScriptPath & "\IE10-Windows6.1-x64-en-us.exe /quiet /update-no /closeprograms /norestart /log:C:\Windows\Logs\", 0 , virkelig)If objFSO.FolderExists("C:\Windows\SysNative") Then'Run non-redirected to 64-bit DISMReturn = objShell.Run("C:\Windows\SysNative\dism.exe /online /add-package /packagepath:" & strScriptPath & "\IE10_x64\IE-Win7.CAB /quiet /norestart",0,True)Other thingsReturn = objShell.Run("dism.exe /online /add-package /packagepath:" & strScriptPath & "\IE10_x64\IE-Win7.CAB /quiet /norestart",0,True)In the case ofif return = 3010 thenLogFile.WriteLine(now & "- WARNING: The installation of Internet Explorer 10 was completed successfully, but a required restart was suppressed!")WScript.exit(0)ElseIf returns <> 0 thenLogFile.WriteLine(Now & " - ERROR: Internet Explorer 10 installation failed, ERROR: " & RETURN)Other thingsLogFile.WriteLine(Now & "- The installation of Internet Explorer 10 has completed successfully.")In the case of'32 bit installation'------------------------------------------------ -------------------------------------------------- ------------------ElseIf OSBitLevel = 32 Then'Install the 32-bit patch for KB2670838 (graphics and image bug fixes)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(Now & "- Install update KB2670838_x86 to resolve graphics and imaging issues...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2670838-x86.msu /quiet /norestart",0,True)result("KB2670838_x86")'Installer 32-bit patch til KB2729094 (Segoe font fix)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(now & "- Installing update KB2729094_x86 for Segoe font fix...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2729094-v2-x86.msu /quiet /norestart",0,True)result("KB2729094_x86")'Install 32-bit patch of KB2731771 (local/UTC time conversion)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(Now & "- Installing update KB2731771_x86 to fix local/UTC time conversion...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2731771-x86.msu /quiet /norestart",0,True)result("KB2731771_x86")'Install the 32-bit patch for KB2533623 (Insecure Library Fixes)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(now & "- Installing update KB2533623_x86 to fix unsafe libraries...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2533623-x86.msu /quiet /norestart",0,True)result("KB2533623_x86")'Install 32-bit patch for KB2786081 (IE storage of credentials)'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(now & "- Installing update KB2786081_x86 to fix IE credential storage...")Return = objShell.Run("wusa.exe " & strScriptPath & "\Windows6.1-KB2786081-x86.msu /quiet /norestart",0,True)result("KB2786081_x86")'Installer 32-bit Internet Explorer 10'------------------------------------------------ -------------------------------------------------- ------------------LogFile.WriteLine(Now & "- Installing Internet Explorer 10...")LogFile.WriteLine(Now & " - Installationslog: " & strLogFolder & "Microsoft_IE_10.log")'Factory Installer: Return = objShell.Run(strScriptPath & "\IE10-Windows6.1-x86-en-us.exe /quiet /update-no /closeprograms /norestart /log:C:\Windows\Logs\", 0 , virkelig)Return = objShell.Run("dism.exe /online /add-package /packagepath:" & strScriptPath & "\IE10_x86\IE-Win7.CAB /quiet /norestart",0,True)if return = 3010 thenLogFile.WriteLine(now & "- WARNING: The installation of Internet Explorer 10 was completed successfully, but a required restart was suppressed!")WScript.exit(0)ElseIf returns <> 0 thenLogFile.WriteLine(Now & " - ERROR: Internet Explorer 10 installation failed, ERROR: " & RETURN)Other thingsLogFile.WriteLine(Now & "- The installation of Internet Explorer 10 has completed successfully.")In the case ofIn the case oflogfile.close'Work'------------------------------------------------ -------------------------------------------------- ------------------function result (name of the knowledge base)select case returnSag 9009LogFile.WriteLine(Now & " - Warning: " & KBname & " is already installed; skipping installation.")Sag 2359302LogFile.WriteLine(Now & " - Warning: " & KBname & " is already installed; skipping installation.")Sag-2145124329LogFile.WriteLine(Now & " - Warning: " & KBname & " is not required for this system; installation skipped.")Other mattersLogFile.WriteLine(now & " - installation " & KBname & " completed, return code: " & RETURN)exit selectionexit function
opens in a new window
Rob.