IVsTextView.GetTextStream 方法

返回文本指定的流字符串中的。

命名空间:  Microsoft.VisualStudio.TextManager.Interop
程序集:  Microsoft.VisualStudio.TextManager.Interop(在 Microsoft.VisualStudio.TextManager.Interop.dll 中)

语法

声明
Function GetTextStream ( _
    iTopLine As Integer, _
    iTopCol As Integer, _
    iBottomLine As Integer, _
    iBottomCol As Integer, _
    <OutAttribute> ByRef pbstrText As String _
) As Integer
int GetTextStream(
    int iTopLine,
    int iTopCol,
    int iBottomLine,
    int iBottomCol,
    out string pbstrText
)
int GetTextStream(
    [InAttribute] int iTopLine, 
    [InAttribute] int iTopCol, 
    [InAttribute] int iBottomLine, 
    [InAttribute] int iBottomCol, 
    [OutAttribute] String^% pbstrText
)
abstract GetTextStream : 
        iTopLine:int * 
        iTopCol:int * 
        iBottomLine:int * 
        iBottomCol:int * 
        pbstrText:string byref -> int
function GetTextStream(
    iTopLine : int, 
    iTopCol : int, 
    iBottomLine : int, 
    iBottomCol : int, 
    pbstrText : String
) : int

参数

  • iTopLine
    类型:Int32

    [in] 定义文本流的顶部行索引。

  • iTopCol
    类型:Int32

    [in]定义文本流的顶部行列。 Viewcol 坐标可以包括虚拟空间。

  • iBottomLine
    类型:Int32

    [in] 基于定义文本流的行索引。

  • iBottomCol
    类型:Int32

    [in] 定义文本流的底部行列。 Viewcol 坐标可以包括虚拟空间。

  • pbstrText
    类型:String%

    [out] 对包含文本的字符串的指针。

返回值

类型:Int32
如果方法成功,则返回 S_OK。如果失败,它会返回一个错误代码。

备注

COM 签名

从 textmgr.idl:

HRESULT IVsTextView::GetTextStream(
   [in] long iTopLine,
   [in] ViewCol iTopCol,
   [in] long iBottomLine,
   [in] ViewCol iBottomCol,
   [out] BSTR * pbstrText
);

.NET Framework 安全性

请参阅

参考

IVsTextView 接口

Microsoft.VisualStudio.TextManager.Interop 命名空间