strComputer = "."
Set objWMIService = GetObject("winmgmts:" _
& "{impersonationLevel=impersonate}!\" & strComputer & "rootcimv2")
Set IPConfigSet = objWMIService.ExecQuery _
("Select * from Win32_NetworkAdapterConfiguration Where IPEnabled=TRUE")
For Each IPConfig in IPConfigSet
If Not IsNull(IPConfig.IPAddress) Then
For i=LBound(IPConfig.IPAddress) to UBound(IPConfig.IPAddress)
WScript.Echo IPConfig.IPAddress(i)
Next
End If
Next
Wednesday, 8 December 2010
Script ile bilgisayardaki IP ve MAC adreslerini listelemek
Asagidaki scripti kullanarak bilgisayarinizdaki tum network kartlari icin atanmis IP adreslerini listeleyebilirsiniz. Scripti calistirdiginizda size IP ve adreslerinizi sirayla gosterecektir.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment