O'Reilly logo

The .NET Developer’s Guide to Directory Services Programming by Joe Kaplan, Ryan Dunn

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

A. Three Approaches to COM Interop with ADSI

Throughout the book, we have mentioned that it is useful and occasionally even necessary to do some kind of COM interop with ADSI when using System.DirectoryServices (SDS). For example, it is useful for harnessing the IADsNameTranslate interface and it is necessary for setting attributes with the LargeInteger syntax (2.5.5.16, see Chapter 6).

There are actually three different approaches we can use for COM interop:

• The “standard” method, where an interop assembly is generated with tlbimp.exe or by setting a COM reference to activeds.tlb in Visual Studio .NET

• The reflection method, where we use types in the System.Reflection namespace to discover and invoke ADSI COM interface methods dynamically ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required