3.1.1.2.3 Conversion Rules for String Values Specified by the Server to the Client

When returning string values as output parameters for methods where the method allows for both Unicode and 8-bit character representations, the server MUST follow these conversion rules.

If the native type of a property is PtypString and the client has requested that property with the type PtypString8, the server MUST convert the Unicode representation to an 8-bit character representation in the codepage specified by the CodePage field of the pStat parameter prior to returning the value.

If the native type of a property is PtypString and the client has requested that property with the type PtypString, the server MUST return the Unicode representation unmodified.

If the native type of a property is PtypString8 and the client has requested that property with the type PtypString, the server MUST convert the 8-bit character representation to a Unicode representation prior to returning the value. The 8-bit character representation is considered to be in the codepage CP_TELETEX.

If the native type of a property is PtypString8 and the client has requested that property with the type PtypString8, the server MUST return the 8-bit character representation unmodified.

Servers MAY<7> undertake other conversions and substitutions for specific properties.

The following table specifies NSPI methods, that are capable of returning string values in both Unicode and 8-bit character representations, and the methods for which the conversion rules are applicable.

 Method

 Description

NspiGetTemplateInfo

String values can be returned in the output parameter ppData.

NspiGetSpecialTable

String values can be returned in the output parameter ppRows.

NspiGetProps

String values can be returned in the output parameter ppRows.

NspiQueryRows

String values can be returned in the output parameter ppRows.

NspiGetMatches

String values can be returned in the output parameter ppRows.

NspiSeekEntries

String values can be returned in the output parameter ppRows.

NspiResolveNames

String values can be returned in the output parameter ppRows.

NspiResolveNamesW

String values can be returned in the output parameter ppRows.