webnetworks
April 9th, 2001, 05:28 AM
Hi,
How do I retrieve the IP address and optional the host name (can be done by a PING) for each active network and dial-up connection on a Win2K machine?
Jeroen.
Iouri
April 9th, 2001, 07:33 AM
Try
shell to "IPCONFIG /ALL > INFO.TXT" then read the INFO.TXT file for your information.
For some reason SHELL "ipconfig.exe /all > file.txt" does not work but
SHELL "command.exe /c ipconfig.exe /all > file.txt" does.
Iouri Boutchkine
iouri@hotsheet.com
webnetworks
April 10th, 2001, 01:30 AM
Hi,
There's no possibility to use a shell, the system that's running the application is loaded with policies and the application that needs the address is run as a service.
Since the used connection might be any kind of IP connection (LAN, WAN, Dial-Up) the address can change dynamically when using Dial-Up. It's a bit strange to pop-up a shell every minute or so. That will become highly anoying.
Thanks for your reply.
Jeroen.