Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

VBscript to run a Windows Client side extensions

Status
Not open for further replies.

jfrasier

Technical User
Apr 5, 2000
33
US
When I run this script a Windows box appears that says "Open File - Security Warning. Do you want to run this file?"

I don't know how to pre-answer that question so I can run the script quietly.

I got this script from someone else and don't really know much about it. I think I am including the part that needs editing to eliminate that 'yes' answer.

'Run correct patch install
Set objShell = CreateObject("Wscript.Shell")

Select Case Left(strOSVer, 3)
.......
Case "5.1"
'Windows XP
If Left(strSysType,3) = "X86" Then
'x86 PC
objShell.Run strPath_XPx86 & " /quiet /log:C:\KB943729.log",0,True
ElseIf Left(strSysType,3) = "X64" Then
'x64 PC
objShell.Run strPath_XPx64 & " /quiet /log:C:\KB943729.log",0,True
End If
End Select

Thanks.
 
which file causes the popup?
if it is the KB97896096.exe that is doing it then you can do two things:
1. right click on the exe file and select properties. in the properties tab make sure you click 'unblock'
2. set a dos environment variable of "see_no_masks" or something like that

+ infact it may also work if its your .vbs which is causing the dialogue

e.g.
set oShell= CreateObject(“Wscript.Shell”)
set oEnv = oShell.Environment(“PROCESS”)
oEnv(“SEE_MASK_NOZONECHECKS”) = 1
oShell.Run “command.exe”,0,True
oEnv.Remove(“SEE_MASK_NOZONECHECKS”)

+ if it doesnt solve your problem then you may need to look at IEZone entries in the registry

I Hear, I Forget
I See, I Remember
I Do, I Understand

Ronald McDonald
 
Thanks so much. It was kb.exe and I unblocked it in properties. I had never noticed that option before.

Jane
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top