Udostępnij za pośrednictwem


IVsTextStream.InitializeContent(String, Int32) Method

Definition

Initializes the content of the text buffer.

public:
 int InitializeContent(System::String ^ pszText, int iLength);
public:
 int InitializeContent(Platform::String ^ pszText, int iLength);
int InitializeContent(std::wstring const & pszText, int iLength);
public int InitializeContent (string pszText, int iLength);
abstract member InitializeContent : string * int -> int
Public Function InitializeContent (pszText As String, iLength As Integer) As Integer

Parameters

pszText
String

[in] Text to insert into the buffer.

iLength
Int32

[in] Number of characters to be inserted.

Returns

If the method succeeds, it returns S_OK. If it fails, it returns an error code.

Implements

Remarks

COM Signature

From textmgr.idl:

HRESULT IVsTextStream::InitializeContent(  
   [in] const WCHAR *pszText,  
   [in] long iLength  
);  

This method will fail unless called on a new untitled buffer.

Applies to