Tu parles de l'accent de "réseau"?Tlem a écrit :Attention aux accents.
Si oui comment je dois l'écrire vu que même en l'écrivant "reseau" ça ne fonctionne pas?
Merci par avance

Tu parles de l'accent de "réseau"?Tlem a écrit :Attention aux accents.

Code : Tout sélectionner
ECHO Réseau>C:\Con.txt
Code : Tout sélectionner
RunWait(@ComSpec & " /c netsh interface ip add wins 'Connexion au r‚seau local' 128.1.79.2")
RunWait(@ComSpec & " /c netsh interface ip add wins 'Connexion au r‚seau local' 128.1.71.36")Code : Tout sélectionner
;Ajout des WINS sur Connexion au réseau local
run(@ComSpec)
WinWaitActive("C:\WINDOWS\system32\cmd.exe")
Send('netsh interface ip add wins "Connexion au réseau local" 128.1.71.36')
send("{ENTER}")
sleep(4000)
Send('netsh interface ip add wins "Connexion au réseau local" 128.1.79.2')
send("{ENTER}")
sleep(4000)
Send("exit")
send("{ENTER}")
Code : Tout sélectionner
RegWrite("HKLM\SYSTEM\ControlSet001\Services\NetBT\Parameters\Interfaces\Tcpip_{751FD231-CB48-4990-9AF9-597E02DB5913}","NameServerList","REG_MULTI_SZ","128.1.71.36" & @LF & "128.1.79.2")
RegWrite("HKLM\SYSTEM\ControlSet001\Services\NetBT\Parameters\Interfaces\Tcpip_{751FD231-CB48-4990-9AF9-597E02DB5913}","DhcpNameServerList","REG_MULTI_SZ","128.1.79.2" & @LF & "128.1.71.36")
Code : Tout sélectionner
Func step51($adresse_integration, $masque_integration, $passerelle_integration, $dns_prefere, $dns_auxiliaire, $Cx)
SplashTextOn("Configuration IP", "Configuration IP en cours ...", 400, 50, -1, -1, 33, -1, 18)
Sleep(1000)
FileMove("c:\PICARD - automation 2.exe", @DesktopDir & "\PICARD - automation 2.exe")
RunWait(@ComSpec & ' /c ' & 'netsh int ip reset c:\windows\temp\temp.txt', "", @SW_HIDE)
RunWait(@ComSpec & ' /c ' & 'netsh interface ip set address local static ' & $adresse_integration & ' ' & $masque_integration & ' ' & $passerelle_integration & ' 1', "", @SW_HIDE)
RunWait(@ComSpec & ' /c ' & 'netsh interface ip set dns ' & '"' & $Cx & '"' & ' static ' & $dns_prefere & ' primary', "", @SW_HIDE)
RunWait(@ComSpec & ' /c ' & 'netsh interface ip add dns ' & '"' & $Cx & '"' & ' ' & $dns_auxiliaire & ' index=2', "", @SW_HIDE)
SplashTextOn("Configuration IP", "Configuration IP terminée.", 400, 50, -1, -1, 33, -1, 18)
Sleep(1000)
SplashOff()
IniWrite($fichier_ini, "Avancement", "Etat", "1")
EndFunc ;==>step51Code : Tout sélectionner
Func step1($adresse_mag, $masque_mag, $passerelle_mag, $dns_prefere, $dns_auxiliaire, $Cx)
SplashTextOn("Configuration IP", "Paramétrage réseau en cours ...", 400, 50, -1, -1, 33, -1, 18)
Sleep(1000)
RunWait(@ComSpec & ' /c ' & 'netsh interface ip reset c:\windows\temp\temp.txt', "", @SW_HIDE)
RunWait(@ComSpec & ' /c ' & 'netsh interface ip set address ' & '"' & $Cx & '"' & ' static ' & $adresse_mag & ' ' & $masque_mag & ' ' & $passerelle_mag & ' 1', "", @SW_HIDE)
RunWait(@ComSpec & ' /c ' & 'netsh interface ip set dns ' & '"' & $Cx & '"' & ' static ' & $dns_prefere & ' primary', "", @SW_HIDE)
RunWait(@ComSpec & ' /c ' & 'netsh interface ip add dns ' & '"' & $Cx & '"' & ' ' & $dns_auxiliaire & ' index=2', "", @SW_HIDE)
SplashTextOn("Configuration IP", "Configuration IP terminée.", 400, 50, -1, -1, 33, -1, 18)
Sleep(1000)
SplashOff()
EndFunc ;==>step1
Code : Tout sélectionner
SplashTextOn("Modif. nom", "Modif. nom PC en cours ...", 400, 50, -1, -1, 33, -1, 18)
RegWrite($sCtrlKey & "\Control\Computername\ActiveComputername", "ComputerName", "REG_SZ", $sCmpName)
RegWrite($sCtrlKey & "\Control\Computername\Computername", "ComputerName", "REG_SZ", $sCmpName)
RegWrite($sCtrlKey & "\Services\Tcpip\Parameters", "Hostname", "REG_SZ", $sCmpName)
RegWrite($sCtrlKey & "\Services\Tcpip\Parameters", "NV Hostname", "REG_SZ", $sCmpName)
RegWrite($sLogonKey, "AltDefaultDomainName", "REG_SZ", $sCmpName)
RegWrite($sLogonKey, "DefaultDomainName", "REG_SZ", $sCmpName)
RegWrite("HKEY_USERS\.Default\Software\Microsoft\Windows Media\WMSDK\General", "Computername", "REG_SZ", $sCmpName)
SplashTextOn("Modif. nom", "Modif. nom PC terminée.", 400, 50, -1, -1, 33, -1, 18)