Reading Known Directory Objects : Read : Directory Services C# Examples


C# Examples » Directory Services » Read »

 

Reading Known Directory Objects









    
using  System;
using  System.DirectoryServices;

public  class  MainClass
{
    public  static  int  Main(string[]  args)
    {
        DirectoryEntry  MyObject  =  new  DirectoryEntry();
        MyObject.Path  =  "LDAP://HMSRevenge/OU=Users,DC=Test,DC=com";

        foreach(string  MyValue  in  MyObject.Properties["email"])
            Console.WriteLine("Email"  +  "  :  "  +  MyValue);

        return  0;

    }
}
    
   
  
   




HTML code for linking to this page:

Follow Navioo On Twitter

C# Examples

 Navioo Directory Services
» Read