Directory Entry Configuration Settings Technology Sample
This sample shows how to get and set directory entry configuration settings using the DirectoryEntryConfiguration class.
Note |
---|
This sample uses fictitious values and cannot be run until it is modified with real values. |
For information about using the samples, see the following topics:
To customize the sample for your settings
Modify the following string variables with real values in the DirEntryConfig.cs or DirEntryConfig.vb file, depending on which version of the sample is being built:
- domainADsPath - LDAP path to domain
To build the sample
At a command prompt, navigate to the Technologies\DirectoryServices\DirEntryConfig directory. Navigate to the CS or VB directory, depending on which version of the sample is being built. For information about required settings and the SDK command prompt, see How to: Set Sample Settings.
Type msbuild direntryconfig.sln at the command line.
To run the sample
At a command prompt, navigate to the directory that contains the built executable file.
Type direntryconfig and press Enter.
Note |
---|
This sample is a console application. You must start and run it at a command prompt window to view its output. |
Remarks
This sample lists the following information:
Current server name
Page size
Password encoding and port number
Referral
Security masks
Whether mutual authentication is in effect
This sample demonstrates the following tasks:
How to create a DirectoryEntry object for the specified path
How to get and set properties such as PageSize, Referral, SecurityMasks, PasswordEncoding and PasswordPort in a DirectoryEntryConfiguration object