The new Microsoft Security Essentials is out in beta, and here's how to install it silently using a VBscript. You still need to tweak it for UAC unless you adapt the command string for use within something else like ConfigMgr. Enjoy…
const x86 = "mseinstall_en_us_x86.exe"
const x64 = "mseinstall_en_us_amd64.exe"
Function ScriptPath()
ScriptPath = Replace(wscript.ScriptFullName, "\" & wscript.ScriptName, "")
End Function
Set fso = createobject("Scripting.FileSystemObject")
If fso.FolderExists("c:\Program Files (x86)") Then
cmd = x64
Else
cmd = x86
End If
cmdpath = ScriptPath() & "\" & cmd
If fso.FileExists(cmdpath) Then
Set objShell = CreateObject("Wscript.Shell")
objShell.Run cmdpath & " /s /runwgacheck /o", 1, True
Set objShell = Nothing
Else
wscript.echo cmdpath & " not found"
End If
Set fso = Nothing
No comments:
Post a Comment