Article ID: 269181 - View products that this article applies to.
This article was previously published under Q269181
Some attributes on Active Directory objects are composed of bitwise flags. You may need to query for objects using a bitwise operator to return only objects that match a particular bit being set. Use the Lightweight Directory Access Protocol (LDAP) Matching Rule controls to do this.
The format of the LDAP Matching Rule has the following syntax:
attributename:ruleOID:=valuewhere attributename is the LDAPDisplayName of the attribute, ruleOID is the object ID (OID) for the matching rule control, and value is the decimal value you want to use for comparison. You need to convert from hexadecimal to decimal.
The value of ruleOID can be one of the following:
The following Microsoft Visual Basic sample script uses the above bitwise comparison filter:
For more information on how to use the LDAP Matching Rule, see the Platform Software Development Kit (SDK). This information is found in the Contents at:
For more information on how to use the LDAP Matching Rule, see the samples included in the Platform SDK. These samples are located in the \Microsoft PlatformSDK\Samples\NetDs\ADSI\Samples\ActiveDir\Attributes and SDK\Samples\NetDs\ADSI\Samples\ActiveDir\GetSchemaInfo folders.
Networking and Directory Services Active Directory, ADSI, and Directory Services Active Directory Using Active Directory Searching the Active Directory Creating a Query Filter How to Specify Comparison Values
Article ID: 269181 - Last Review: February 8, 2006 - Revision: 3.0
Contact us for more help
Connect with Answer Desk for expert help.