Bonjour,
j'ai trouvé un petit script sympa pour faciliter le changement d'adresse ip que je dois faire tous les jours au boulot.
Le script me demande bien les infos nécessaire mais rien ne ce passe à la fin?
Voici le script, quelqu'un sait m'aider ?

Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
@echo off 
echo Choose: 
echo [A] Set Static IP 
echo [B] Set DHCP 
echo. 
:choice 
SET /P C=[A,B]? 
for %%? in (A) do if /I "%C%"=="%%?" goto A 
for %%? in (B) do if /I "%C%"=="%%?" goto B 
goto choice 
:A 
@echo off 
echo "Please enter Static IP Address Information" 
echo "Static IP Address:" 
set /p IP_Addr=

echo "Default Gateway:" 
set /p D_Gate=

echo "Subnet Mask:" 
set /p Sub_Mask=

echo "Setting Static IP Information" 
netsh interface ip set address "LAN" static %IP_Addr% %Sub_Mask% %D_Gate% 1 
netsh int ip show config 
pause 
goto end

:B 
@ECHO OFF 
ECHO Resetting IP Address and Subnet Mask For DHCP 
netsh int ip set address name = "LAN" source = dhcp

ipconfig /renew

ECHO Here are the new settings for %computername%: 
netsh int ip show config

pause 
goto end 
:end

Script END!

Merci à vous