I'm writing a vb script , that has gui , and also write to the registry , and install certificate that i have.
after writing the code i'm using iexpress , to create an exe file that will run all the files (cer and reg files) and install my script .
the problem is that i don't see the reg and certicate installing .
test=MsgBox("To configure wsus on you pc",4,"Wsus installation")
If test = yes Then
Set WshShell = Wscript.CreateObject("Wscript.Shell")
shell 'regedit -add "\\WSUS.reg"'
shell 'certmgr -add -c "\\wsus.cer" -s -r localMachine root'
shell 'certmgr -add -c "\\wsus.cer" -s -r localMachine trustedpublisher'
RestartServices "localhost", "wuauserv"
If Err.Number <> 0 Then
MsgBox (Err.number & "-" & err.Description)
else
MsgBox "Certificate Install completed"
End If
Else
End If