For that purpose,
You can use "net view" shell command and redirect output to your
control.
For example you can redirect shell output to textbox using:
Dim start_info As New ProcessStartInfo("cmd.exe", "/c net view")
start_info.UseShellExecute = False
start_info.CreateNoWindow = True
start_info.RedirectStandardOutput = True
start_info.RedirectStandardError = True
' Make the process and set its start information.
Dim proc As New Process()
proc.StartInfo = start_info
' Start the process.
proc.Start()
' Attach to stdout and stderr.
Dim std_out As IO.StreamReader = proc.StandardOutput()
' Display the results to your textbox1
TextBox1.Text = std_out.ReadToEnd()
' Clean up.
std_out.Close()
proc.Close()
But i suppose System.net.dns class provides LAN IPs and you can loop
through the array.