Platform SDK: Certificate Enrollment Control

ICEnroll2::EnableT61DNEncoding [C++]

CEnroll.EnableT61DNEncoding [Visual Basic]

The EnableT61DNEncoding property is used to control whether the distinguished name in the request is encoded as a T61 string instead of as a UNICODE string. A T61 character is 8 bits, hence all UNICODE characters to be encoded must be less than or equal to 0xFF.

[Visual Basic]
objEnroll.EnableT61DNEncoding [ = bValue ]
[C++]
HRESULT put_EnableT61DNEncoding(BOOL bValue);
HRESULT get_EnableT61DNEncoding(BOOL * pbValue);

Parameters

[Visual Basic] objEnroll
Object expression that resolves to a CEnroll object.
[Visual Basic,C++] bValue
A boolean value assigned to the EnableT61DNEncoding property. It is one of the following values:
[C++] pbValue
Pointer to retrieved property value.

Remarks

EnableT61DNEncoding affects the behavior of the following methods:

Example Code [C++]

BOOL     bT61DN;
HRESULT  hr;

// pEnroll is previously instantiated ICEnroll2 interface pointer

// get the EnableT61DNEncoding boolean value
hr = pEnroll->get_EnableT61DNEncoding( &bT61DN );
if ( FAILED ( hr ) )
    printf("Failed get_EnableT61DNEncoding - %x\n", hr );
else
    printf( "T61DNEncoding: %s\n", 
             ( bT61DN ? "Enabled" : "Disabled" ) );

// set the EnableT61DNEncoding value
hr = pEnroll->put_EnableT61DNEncoding( TRUE );
if ( FAILED ( hr ) )
    printf("Failed Setting EnableT61DNEncoding - %x\n", hr );
else
    printf( "EnableT61DNEncoding was set to TRUE\n" ); 

Example Code [Visual Basic]

' declare Certificate Enrollment Control object
Dim objXen As Object

Dim bT61DN As Boolean

' instantiate the object
Set objXen = CreateObject("CEnroll.CEnroll.1")

' retrieve and display the EnableT61DNEncoding
bT61DN = objXen.EnableT61DNEncoding
MsgBox bT61DN, vbOKOnly, "EnableT61DNEncoding"

' set the EnableT61DNEncoding
objXen.EnableT61DNEncoding = True

Requirements

  Windows NT/2000: Requires Windows 2000.
  Header: Declared in Xenroll.h.
  Library: Use Uuid.lib.