Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

9 lines
374 B

  1. set IPConfigSet = GetObject("winmgmts:{impersonationLevel=impersonate}").ExecQuery _
  2. ("select IPAddress from Win32_NetworkAdapterConfiguration where IPEnabled=TRUE")
  3. for each IPConfig in IPConfigSet
  4. if Not IsNull(IPConfig.IPAddress) then
  5. for i=LBound(IPConfig.IPAddress) to UBound(IPConfig.IPAddress)
  6. WScript.Echo IPConfig.IPAddress(i)
  7. next
  8. end if
  9. next