IVsHTMLConverter.ConvertToEntities(String, UInt32, UInt16[], UInt32) 方法

定义

将字符串转换为包含实体引用的字符串,例如字符“ä”的“ä”。

public:
 int ConvertToEntities(System::String ^ szToConvert, System::UInt32 cchBuffSize, cli::array <System::UInt16> ^ szBuffer, [Runtime::InteropServices::Out] System::UInt32 % pcchBuffSizeActual);
int ConvertToEntities(std::wstring const & szToConvert, unsigned int cchBuffSize, std::Array <unsigned short> const & szBuffer, [Runtime::InteropServices::Out] unsigned int & pcchBuffSizeActual);
public int ConvertToEntities (string szToConvert, uint cchBuffSize, ushort[] szBuffer, out uint pcchBuffSizeActual);
abstract member ConvertToEntities : string * uint32 * uint16[] * uint32 -> int
Public Function ConvertToEntities (szToConvert As String, cchBuffSize As UInteger, szBuffer As UShort(), ByRef pcchBuffSizeActual As UInteger) As Integer

参数

szToConvert
String

[in]要转换的字符串。

cchBuffSize
UInt32

[in]要在其中存储转换的字符串的缓冲区的长度。

szBuffer
UInt16[]

[out]包含转换后的字符串的缓冲区。

pcchBuffSizeActual
UInt32

[out]所用缓冲区的实际大小。

返回

如果该方法成功,则它会返回 S_OK。 如果该方法失败,则会返回错误代码。

注解

COM 签名

从 vsshell.idl:

HRESULT IVsHTMLConverter::ConvertToEntities(  
   [in] LPCOLESTR szToConvert,   
   [in] ULONG cchBuffSize,   
   [in, out, size_is(cchBuffSize)] OLECHAR szBuffer[],   
   [out] ULONG *pcchBuffSizeActual  
);  

适用于