?
Solved

Network Neighbourhood - my neighbours?

Posted on 2001-06-14
7
Medium Priority
?
236 Views
Last Modified: 2012-05-04
Hi,

I'm Riaz.  I would like to know how to programatically (in VB) find out all the computers active on the network currently - like windows explorer shows them when you click on Network Neighbourhood.

thanx in advance
0
Comment
Question by:riaz9
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
7 Comments
 

Accepted Solution

by:
vbhelper earned 400 total points
ID: 6194640
NOTE: You may not see the Active DS Type Library in the list of available References. To add the Library to the list:

Click Browse.

 -Go to the Windows\System folder or WinNT\System32 folder.
 -Select the file ActiveDS.tlb.
 -From now on, the Active DS Type Library is among the list of available References.


Dim dc As IADsDomain
Dim n As IADsComputer
 
 Set dc = GetObject("WinNT://DomainName")
 dc.Filter = Array("Computer")
 For Each n In dc
    Debug.Print n.Name
 
 Next
 Set dc = Nothing
 Set n = Nothing

Cheer's
0
 
LVL 43

Expert Comment

by:TimCottee
ID: 6194710
vbhelper, you are not new to EE so you should be fully aware of the guidelines on comments vs answers. Whilst your "answer" does indeed contribute to this thread it cannot be construed as the 100% definitive solution. Please restrain from posting "answers" in this manner or your account will be referred to customer services for possible penalty. I would ask you to withdraw your answer but as this is currently not available I would hope that your answer is rejected and considered fairly with the posts from hongjun. IMO the MVPS link provides a fast and efficient solution to this without having to install additional components such as the ADSI stuff. You are fully aware that the questioner may accept any comment as an answer at any time and as such your posting of an answer is in fact irrelevant. All that it achieves is to move the question into the locked area thus reducing the chance of other experts to contribute.
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
LVL 33

Expert Comment

by:hongjun
ID: 6195798
vbhelper, yours work only on NT version. Use my first link which will work for all windows version.

hongjun
0
 
LVL 28

Expert Comment

by:Ark
ID: 6197418
Hi
Add listbox to your form:

Private Sub Form_Load()
  Const ssfNETWORK = &H12
  Dim oShell, fld, fldItm
  Set oShell = CreateObject("Shell.Application")
  Set fld = oShell.NameSpace(ssfNETWORK)
  For Each fldItm In fld.Items
     List1.AddItem fldItm.Name
  Next
  Set fldItm = Nothing
  Set fld = Nothing
  Set oShell = Nothing
End Sub

Cheers
0
 
LVL 33

Expert Comment

by:hongjun
ID: 6199297
riaz9, you got to reply.

hongjun
0
 
LVL 1

Author Comment

by:riaz9
ID: 6217220
thanx for the all the help
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction While answering a recent question about filtering a custom class collection, I realized that this could be accomplished with very little code by using the ScriptControl (SC) library.  This article will introduce you to the SC library a…
If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Suggested Courses
Course of the Month11 days, 19 hours left to enroll

752 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question