Get AD computer list in VB

  • Thread starter Thread starter ZIDAC
  • Start date Start date
Z

ZIDAC

Hi, I am from Spain, excuse my Inglish

I want to get AD computer list in VB2008 when i press a button
the list show in a listbox for select one

Can I help me?

Thanks for all and excuse again my Inglish
ZIDAC
 
Hi, I am from Spain, excuse my Inglish

I want to get AD computer list in VB2008 when i press a button
the list show in a listbox for select one

Can I help me?

Thanks for all and excuse again my Inglish
ZIDAC

Hi ZIDAC,
Though you can find more samples on getting list of AD computers,
basically it's done with these classes:
System.DirectoryServices.DirectoryEntry
System.DirectoryServices.DirectorySearcher

Don't forget you "may" need to add reference to
System.DirectoryServices.dll.

And here are some sample code to get AD computers, in code you can add
items into your listbox control using a "for" loop.(untested):
http://aspalliance.com/801_CodeSnip_Get_a_complete_computer_list_from_Active_Directory_using_NET_20
http://www.vbdotnetheaven.com/Uploa...1AM/ListingAllComputersinActiveDirectory.aspx
http://www.codeproject.com/KB/system/active_directory_in_vbnet.aspx


Hope this helps,

Onur Güzel
 
Back
Top