共用方式為


GetTnefStreamCodepage

Applies to: Office 2010 | Outlook 2010 | Visual Studio

Determines the code page for a Transport-Neutral Encapsulation Format (TNEF) stream.

Header file:

tnef.h

Implemented by:

MAPI

Called by:

Client applications and service providers.

HRESULT GetTnefStreamCodepage ( 
  LPSTREAM lpStream, 
  ULONG FAR * lpulCodepage, 
  ULONG FAR * lpulSubCodepage
);

Parameters

  • lpStream
    [in] Pointer to a storage stream object OLE IStream interface providing a source for a TNEF stream message.

  • lpulCodepage
    [out] Pointer to the code page of the stream.

  • lpulSubCodepage
    [out] Pointer to the subcode page of the stream.

Return Value

  • S_OK
    The call succeeded and has returned the expected value or values.

  • MAPI_E_NOT_ENOUGH_DISK
    There was an error reading an attribute in the TNEF stream.

  • MAPI_E_CORRUPT_DATA
    Either the stream was not a TNEF stream or there was an error reading the attOemCodepage attribute.

Remarks

Use the GetTnefStreamCodepage function to read the attOemCodepage attribute of the TNEF stream to determine the code page and subcode page. If attOemCodepage is not found, GetTnefStreamCodepage returns a code page of 437 and a subcode page of 0.

See Also

Other Resources

attOemCodepage