?
Solved

Shortcut to TCP/IP Properties

Posted on 2005-04-01
5
Medium Priority
?
4,192 Views
Last Modified: 2008-01-09
I'm sick of the constant clicking I have to do to get to the TCP/IP properties, as I change my IP a lot when configureing equiptment.

is there a shortcut i can type in RUN to get to it?

for example to get to Calculator you can type calc and command you type cmd.

0
Comment
Question by:bluebirds1984
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 2

Assisted Solution

by:jordi169
jordi169 earned 700 total points
ID: 13681606
it's not that easy for this one.  most of your commands that you type in like: calc and ipconfig, are executables located in your system 32 folder.  If you can find the executable that runs the tcp/ip configuration you're golden.  I looked at the system32 briefly but found nothing.
0
 
LVL 11

Accepted Solution

by:
bwalker1 earned 1300 total points
ID: 13682268
I created a shortcut to to my local area connection, placed the shortcut in the %systemroot%\windows\system32 directory and named the shortcut "net".  Now I can go to start->run, type in "net.lnk" and it opens the local area connection window.
0
 
LVL 85

Expert Comment

by:oBdA
ID: 13683017
You can use this script; put it someplace into the path, then call it with the location as argument (or create some shortcuts with the proper arguments).
Just specify the name of the connection to configure, and add locations like the sample locations you find.
To switch between the different settings, simply add the location label without the square brackets as argument; examples:
setip dhcp
setip loc1
setip loc2

====8<----[SetIP.cmd]----
@echo off
setlocal enabledelayedexpansion
:: *** name of the IP connection to configure:
set LAN=LAN Connection

set LogFile=%~dpn0.log
if exist "%LogFile%" del "%LogFile%"
set Location=%1
set Location=%Location:/=%
type %~dpnx0 | find /i ":[%Location%]" >NUL
if errorlevel 1 goto err_Label
goto [%Location%]

:[DHCP]
echo Setting IP address to DHCP ...
netsh interface ip set address name="%LAN%" source=DHCP >>"%LogFile%"
echo Setting DNS address to DHCP ...
netsh interface ip set dns name="%LAN%" source=DHCP >>"%LogFile%"
echo Setting WINS address to DHCP ...
netsh interface ip set wins name="%LAN%" source=DHCP >>"%LogFile%"
echo OK.
goto :eof

:[Loc1]
set IP=192.168.0.10
set NM=255.255.255.0
set GW=192.168.0.1
set DNS0=192.168.0.1
set DNS1=192.168.0.1
set WINS0=192.168.0.1
set WINS1=192.168.0.1
goto SetIP

:[Loc2]
set IP=192.168.1.10
set NM=255.255.255.0
set GW=192.168.1.1
set DNS0=192.168.1.1
set DNS1=192.168.1.1
set WINS0=192.168.1.1
set WINS1=192.168.1.1
goto SetIP

:: **********************************************************************
goto leave
:SetIP
echo Setting IP address %IP% ...
netsh interface ip set address "%LAN%" static %IP% %NM% %GW% 1 >>"%LogFile%"
echo Setting primary DNS server %DNS0% ...
netsh interface ip set dns "%LAN%" static %DNS0% >>"%LogFile%"
for %%a in (1 2 3 4 5 6 7 8 9) do (
  if not "!DNS%%a!"=="" (
    echo Adding DNS server !DNS%%a! ...
    netsh interface ip add dns "%LAN%" !DNS%%a! >>"%LogFile%"
  )
)
echo Setting primary WINS server %WINS0% ...
netsh interface ip set wins "%LAN%" static %WINS0% >>"%LogFile%"
for %%a in (1 2 3 4 5 6 7 8 9) do (
  if not "!WINS%%a!"=="" (
    echo Adding WINS server !WINS%%a! ...
    netsh interface ip add wins "%LAN%" !WINS%%a! >>"%LogFile%"
  )
)
echo OK.
goto :eof

:err_Label
echo.
echo Error: Label "[%Location%]" not defined.
pause
echo.

:leave
====8<----[SetIP.cmd]----
0
 
LVL 4

Author Comment

by:bluebirds1984
ID: 13707418
i'm at work so i wont be creating any scripts, thanks anyway.

the shortest path is probably creating the system32 shortcut, thanks.
0
 

Expert Comment

by:CarloVasquez
ID: 21669063
I found your script above oBdA interesting and I am thinking to give it a shot.

Thought the only problem I have with it is that I have a range of 15 IP addresses and would like the script to increment by the last digit of the IP address by +, every time I run the script.

Is this something possible?

Let me know thanks.
0

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Sometimes people don't understand why download speed shows differently for Windows than Linux.Specially, this article covers and shows the solution for throughput difference for Windows than a Linux machine. For this, I arranged a test scenario.I…
If you have done a reformat of your hard drive and proceeded to do a successful Windows XP installation, you may notice that a choice between two operating systems when you start up the machine. Here is how to get rid of this: Click Start Clic…
Two types of users will appreciate AOMEI Backupper Pro: 1 - Those with PCIe drives (and haven't found cloning software that works on them). 2 - Those who want a fast clone of their boot drive (no re-boots needed) and it can clone your drive wh…
NetCrunch network monitor is a highly extensive platform for network monitoring and alert generation. In this video you'll see a live demo of NetCrunch with most notable features explained in a walk-through manner. You'll also get to know the philos…
Suggested Courses
Course of the Month10 days, 23 hours left to enroll

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question