LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How 2 change the IP address of the PC with Lavbview

Hi every body,
I am developping a Labview 6.1 program on windows 2000. This programm writes bytes on a distant machine with a certain ip configuration (address, mask). The Pc running the programm does not alwys have the same config.
My question: Is there a way to changfe the ip address of the computer through labview (can labview force windows to change the ip address of the pc )?
thanks in advance
0 Kudos
Message 1 of 4
(5,395 Views)
Thanks, it works perfectly.
Now, for the end of my program, I have to re-configure automatically the ip config of the computer (ip address, mask, DHCP or Static...). I would like this function to be non dependant of the windows langage so I am thinking of looking at the
GetInterfaceInfo
IP_INTERFACE_INFO
GetAdaptersInfo
MIB_IPADDRROW
functions of windows, with building a dll in C, but I will have to do that with one of my colleague because I don't know these functions so well.

Maybe there is a solution in labview to know the DHCP / Static mode easily, non dependant of the language ?
0 Kudos
Message 3 of 4
(5,394 Views)
No, there is no way in LabVIEW to access this information in a platform independant way directly. You will have to somehow interface to the underlying OS library.
Although you can get GetInterfaceInfo to work with some work directly from LabVIEW, GetAdaptersInfo is indeed a little to complicated to get it to work without external DLL.

One issue about this functions is that they reside in iphlpapi.dll which supposedly is not available under Windows NT and 95, so it will not even work on all Windows versions.

Rolf Kalbermatter
Rolf Kalbermatter  My Blog
DEMO, Electronic and Mechanical Support department, room 36.LB00.390
Message 4 of 4
(5,394 Views)