How to search Active Directory in Windows XP

  
        

Many people may be surprised by Windows XP: Active Directory can be searched in Windows 2000 Professional, but this feature has been removed in Windows XP. In fact, although users can't use the Active Directory search feature through the graphical user interface provided by Windows XP, it does exist.

There is a little trick to get users to search Active Directory through Windows, which is to use a dynamic link library (DLL) file.

Applications avoid duplicate coding by using dynamic link library files. For example, there is an "Open" command in almost every program's "File" menu, and when you don't know the file name of the file you want to open, you can also click on the "Browse" button to Find the file you want on your hard drive or on a network drive.

Although I am not a programmer, I also know that this "browsing" function is based on a DLL file or something similar, so that different programs can easily call this function. If this is not the case, then as long as someone wants to write a Windows-based application and includes the "file open" feature, then he has to write the code for browsing the file himself. In this case, you may see that many low-end programs have removed this feature because the code is too cumbersome to write. In fact, applications that include the "Browse" feature can be implemented uniformly because they use shared code that is encapsulated in a DLL file.

Back to our topic, how can DLL files help us search Active Directory? Be aware that many applications need to search Active Directory. In Windows XP, the ability to search Active Directory is encapsulated in a DLL file. As long as you can use these DLL files, you can allow users to perform queries and search functions for Active Directory.

You can do this through another operating system component called RUNDLL32.EXE. Note that although it contains a lot of modules and a lot of code, the DLL file itself is not an executable file. Only through RUNDLL32.EXE, a secondary application, you can execute a DLL file. More precisely, in fact, instead of executing a DLL file, you are executing some functions in the DLL file. Most DLL files contain multiple functions, so you should specify the specific function name you need to execute when executing.

Now that you know how DLL files work, let's see how the corresponding commands and parameters should be written when you want to start an Active Directory query. Note that the following commands are case sensitive:

rundll32 dsquery, OpenQueryWindow

DSQIERY is the name of a DLL file, and OpenQueryWindow is the name of the function you are calling. As the name suggests, after executing this command, the system will open a window where you can have different objects in the Active Directory.

Although we usually use "Run" to execute this command, you can also make it into a batch file and then create a desktop shortcut for the batch file. This way you can perform a query on the active directory with a simple double click of the mouse.




Copyright © Windows knowledge All Rights Reserved