Encodings Object

On this page:

Description

This object represents a collection of character encoding objects that can be used when opening or saving text files. Convenience properties/methods are provided to enable easy creation of the most commonly used encodings.

Properties

Count read-only, IEncodings

The number of encodings the collection.

IDL [propget] HRESULT Count([out, retval] long* pValue)
.NET Int32 Count[get]

Default read-only, IEncodings

The default encoding used by Merge to open/save files.

IDL [propget] HRESULT Default([out, retval] IEncoding** pValue)
.NET Encoding Default[get]

Item read-only, IEncodings

Provides access to the encoding at the specified index within the collection.

IDL [propget] HRESULT Item(
    [in] long nIndex,
    [out, retval] IFileSystemItem** pValue)
.NET IFileSystemItem get_Item(
    Int32 nIndex)

Methods

CreateEncoding IEncodings

Creates an encoding object representing a Windows code page.

IDL HRESULT CreateEncoding(
    [in] long codepage,
    [in] VARIANT_BOOL usesByteOrderMarker,
    [out, retval] IEncoding** pValue)
.NET Encoding CreateEncoding(
    Int32 codepage,
    Boolean usesByteOrderMarker)

CreateUCS2Encoding IEncodings

Creates an encoding object representing the UCS-2 character encoding.

IDL HRESULT CreateUCS2Encoding(
    [in] VARIANT_BOOL usesByteOrderMarker,
    [in] VARIANT_BOOL littleEndian,
    [out, retval] IEncoding** pValue)
.NET Encoding CreateUCS2Encoding(
    Boolean usesByteOrderMarker,
    Boolean littleEndian)

CreateUTF8Encoding IEncodings

Creates an encoding object representing the UTF-8 character encoding.

IDL HRESULT CreateUTF8Encoding(
    [in] VARIANT_BOOL usesByteOrderMarker,
    [out, retval] IEncoding** pValue)
.NET Encoding CreateUTF8Encoding(
    Boolean usesByteOrderMarker)