473,322 Members | 1,379 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,322 software developers and data experts.

Need help for lookup in Active Directory using VB.Net

Hi

I need a little help with some VB.Net code..
I am pulling my computer's GUID out using WMI
Dim wmiObj As New System.Management.ManagementObjectSearcher("SELECT UUID FROM Win32_ComputerSystemProduct"
Dim objMgmt As System.Management.ManagementObjec
Dim MyByteGuid As Byte(
Dim MyStringGuid As Strin
Dim MyGuid As Gui
For Each objMgmt In wmiObj.Ge
MyStringGuid = objMgmt("UUID").ToString(
Nex
MyGuid = New Guid(MyStringGuid

This gives me a GUID like: DD5FE69B-2523-11D6-AB9B-FE9338A908D

Now what I need to do i lookup this GUID in the Active Directory, I now that this precise value can be found in the netbootGUID property of my computer account, so I thought it would be like
objSrch.Filter = "(&(objectClass=computer)(netbootGUID=" & MyGuid.ToString() & "))"
This does not work, and the things I've tried with MyGuid.ToByteArray has not worked either..
As far as I can figure out, the Active Directory property contains the bytearray of the value I have, but I can not figure out how to query AD for this value
Does anybody know how I can make the Active Directory lookup on the netbootGUID property ?
I need to find the computers name based on the GUID I get using WMI

All the best
Henning Kristense

Nov 22 '05 #1
0 1395

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Jay Chan | last post by:
We have just installed a SQL Server 2000 (SP 3A) onto a computer that has Windows-2003 Server on it. Now, we cannot get access to that database server from other computers. Seem like this may be an...
0
by: microsoft | last post by:
Hi People, when I try to modify an active directory user programatically, I receive the following exception: The server is unwilling to process the request Reading the microsoft web site, I...
9
by: Mario Rodriguez | last post by:
Hi people. I have a problem adding users to Win2003 active directory programatically. When I execute my app throws the following exception: .................The specified directory service...
0
by: Henning Kristensen | last post by:
Hi I need a little help with some VB.Net code.. I am pulling my computer's GUID out using WMI Dim wmiObj As New System.Management.ManagementObjectSearcher("SELECT UUID FROM...
10
by: huzz | last post by:
I have web application that quaries the Active Directory to get user details.. everything works fine but someday I'll get System.Runtime.InteropServices.COMExection and if I restart the client...
4
by: ptran123 | last post by:
I want to do an AD lookup of the current logged on user. From ASP.NET I can get the identity name of the user in the form of "<domain>\<user>". How do I perform an AD search based on that...
0
by: RTT | last post by:
here is my current situation. I develop a program on my computer's localhost. From there i contact Active directory succesfull using a connectionstring like:...
0
by: mjsterz | last post by:
I've been working with VB .NET for less than a year and this is the first time I've posted on one of these groups, so let me apologize beforehand if I'm being unclear, not posting my issue...
1
by: Grant Merwitz | last post by:
Is it possible to do an anonymous lookup in active directory through a web page? I am running a site with Domain Authentication activated. I am looking up a users email address in Active...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.