Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. List of Active Computers on Network

List of Active Computers on Network

Scheduled Pinned Locked Moved Visual Basic
sysadminquestion
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    Sumit Domyan
    wrote on last edited by
    #1

    How would i get a list of all Active Computers on a network? All I need are the computer names. Method that i am currently using lists all computers even if they're not currently connected to the network. Dim enTry As DirectoryEntry = New DirectoryEntry("LDAP://CORP") Dim mySearcher As DirectorySearcher = New DirectorySearcher(enTry) Dim resEnt As SearchResult mySearcher.Filter = ("(objectClass=computer)") TotalNodesLabel.Text = "Total computers: " + mySearcher.FindAll.Count.ToString For Each resEnt In mySearcher.FindAll() If IsNothing(resEnt) = False Then ListOfNodesListBox.Items.Add(resEnt.GetDirectoryEntry().Name.ToString()) End If Next I was hoping to get a list of active computers, this method lists all computers even if they're not currently connected to the network. Thanks Sumit Domyan

    D 1 Reply Last reply
    0
    • S Sumit Domyan

      How would i get a list of all Active Computers on a network? All I need are the computer names. Method that i am currently using lists all computers even if they're not currently connected to the network. Dim enTry As DirectoryEntry = New DirectoryEntry("LDAP://CORP") Dim mySearcher As DirectorySearcher = New DirectorySearcher(enTry) Dim resEnt As SearchResult mySearcher.Filter = ("(objectClass=computer)") TotalNodesLabel.Text = "Total computers: " + mySearcher.FindAll.Count.ToString For Each resEnt In mySearcher.FindAll() If IsNothing(resEnt) = False Then ListOfNodesListBox.Items.Add(resEnt.GetDirectoryEntry().Name.ToString()) End If Next I was hoping to get a list of active computers, this method lists all computers even if they're not currently connected to the network. Thanks Sumit Domyan

      D Offline
      D Offline
      Dave Kreskowiak
      wrote on last edited by
      #2

      You'll probably have to go down the list your getting and ping them all to determine which ones are live and which are not. RageInTheMachine9532 "...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups