Question : Set static IP based on current IP address

Hello,

I am trying to set a static IP address based on the third oct of the current IP address obtained via DHCP with either a batch file or vb script. Any ideas?

Answer : Set static IP based on current IP address

Oh - I'd copied your updated version...notice my original encloses the tests on both sides in brackets...

if [%ThirdOctet%]==12 goto AssignStatic
will not work - make it:
if [%ThirdOctet%]==[12] goto AssignStatic
Random Solutions  
 
programming4us programming4us