J'ai finis un script VBS pour automatiser l'installation du NET Framework 4, je souhaite en faire un exe de manière à ce que le mot de passe ne soit pas visible, voici mon script :
Code : Tout sélectionner
Set oShell = Wscript.CreateObject("WScript.Shell")
If RegExists ("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Client\Version") = False Then
oShell.Run "runas /user:domaine.local\administrateur ""\\srv-files\dotNetFx40_Full_x86_x64.exe"""
WScript.Sleep 100
oShell.Sendkeys "toto~"
Wscript.Quit
End if
Function RegExists(value)
On Error Resume Next
Set WS = CreateObject("WScript.Shell")
val = WS.RegRead(value)
If (Err.number = -2147024893) or (Err.number = -2147024894) Then
RegExists = False
Else
RegExists = True
End If
End FunctionMerci d'avance



