调用 ADSI

ADSI 接口公开属性(如 IADsUser 接口属性 LastName 和 Firstname)和方法(如 SetPassword)。有关 IADsUser 接口及其属性和方法的详细信息,请参阅 MSDN Library(网址为 https://go.microsoft.com/fwlink/?LinkID=27252)中的 IADsUser 接口、LastName 属性、FirstName 属性和 SetPassword 方法。

System.DirectoryServices 命名空间不包含 ADSI 接口定义的所有方法和属性的包装方法和属性。若要访问在 System.DirectoryServices 命名空间中没有对应包装方法的 ADSI 方法,请使用 Invoke 方法。对于属性,请使用 InvokeMember 方法。本节提供了使用这两个选项的代码示例。

本节包括以下主题:

另请参见

参考

System.DirectoryServices
DirectoryEntry
Type

概念

高级编程主题

Send comments about this topic to Microsoft.

版权所有 (C) 2007 Microsoft Corporation。保留所有权利。