Platform SDK: Active Directory, ADSI, and Directory Services |
The IADsPathname::SetDisplayType method specifies how to display the path name of an object. It can ask the path name to be displayed in a string with both naming attributes and values, that is, "CN=John Doe" or with values only, that is, "John Doe".
HRESULT IADsPathname::SetDisplayType( long lnDisplayType );
This methods supports the standard return values, including the following:
The following Visual Basic® code snippet sets to display the path name in a string with both the naming attribute and the value.
Dim x As New Pathname x.SetDisplayType(ADS_DISPLAY_FULL)
The following VBScript code snippet sets to display the path name in a string with both the naming attribute and the value.
Dim x const ADS_DISPLAY_FULL = 1 Set x = CreateObject("Pathname") x.SetDisplayType(ADS_DISPLAY_FULL)
The following C++ code snippet sets to display the path with both the naming attributes and values. See the code snippet in IADsPathname for the GetPathnameObject function.
LPWSTR adsPath=L"LDAP://server/cn=jsmith,dc=Microsoft,dc=com"; IADsPathname *pPath = GetPathnameObject(adsPath); pPath->SetDisplayType(ADS_DISPLAY_FULL)
Windows NT/2000: Requires Windows 2000 (or Windows NT 4.0 with DSClient).
Windows 95/98: Requires Windows 95 or later (with DSClient).
Header: Declared in Iads.h.