Click here to Skip to main content
15,920,383 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
See more:
I am looking for a way to obtain a domain users PC name by searching a domain using a domain username.

I am a novice when it comes to and have yet to find anything on the net. I have found a way to find local domain information for my own PC, but I cannot seem to search the whole of the domain using a "user name". Thank you in advance.
Casey Sheridan 2-Jul-12 11:14am    
I guess I don't know for sure what you're asking. Are you looking for the names of the computers on a network?

1 solution

If you want the computer name, just use

So, for example,

Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

Label1.text = My.Computer.Name.ToString

End Sub
Share this answer
Danny140 12-Oct-12 5:42am    
Thanks for your response.

Its not my computer name im looking for. I want to retrieve users PC info such as an IP address and computer name on a domain by entering a user name. For example search string "Joe Blogs" from which i can retireve the IP address the user currently has and the machine name the user is using. Hope this helps.
Hemil Gandhi 19-May-20 13:03pm    
Finally you go the solution or not??, I have same requirement.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900