IVsTextLayer.CopyLineText 메서드
지정 된 텍스트 범위가 호출자 할당 버퍼에 넣습니다.
네임스페이스: Microsoft.VisualStudio.TextManager.Interop
어셈블리: Microsoft.VisualStudio.TextManager.Interop(Microsoft.VisualStudio.TextManager.Interop.dll)
구문
‘선언
Function CopyLineText ( _
iStartLine As Integer, _
iStartIndex As Integer, _
iEndLine As Integer, _
iEndIndex As Integer, _
pszBuf As IntPtr, _
<OutAttribute> ByRef pcchBuf As Integer _
) As Integer
int CopyLineText(
int iStartLine,
int iStartIndex,
int iEndLine,
int iEndIndex,
IntPtr pszBuf,
out int pcchBuf
)
int CopyLineText(
[InAttribute] int iStartLine,
[InAttribute] int iStartIndex,
[InAttribute] int iEndLine,
[InAttribute] int iEndIndex,
[InAttribute] IntPtr pszBuf,
[InAttribute] [OutAttribute] int% pcchBuf
)
abstract CopyLineText :
iStartLine:int *
iStartIndex:int *
iEndLine:int *
iEndIndex:int *
pszBuf:IntPtr *
pcchBuf:int byref -> int
function CopyLineText(
iStartLine : int,
iStartIndex : int,
iEndLine : int,
iEndIndex : int,
pszBuf : IntPtr,
pcchBuf : int
) : int
매개 변수
iStartLine
형식: Int32[in] 시작 줄
iStartIndex
형식: Int32[in] 시작 문자 인덱스 줄 (있어야 < = 줄의 길이)
iEndLine
형식: Int32[in] 줄 끝
iEndIndex
형식: Int32[in] 줄 끝 문자 인덱스 (있어야 < = 줄의 길이)
pszBuf
형식: IntPtr[in] 있는 경우 삽입할 텍스트
pcchBuf
형식: Int32%[in, out] 입력에서 복사할 문자 수입니다. 출력에 필요한 버퍼의 크기입니다. 수 없습니다 바이트 유니코드 문자입니다.
반환 값
형식: Int32
메서드가 성공 하면, 반환 S_OK.실패할 경우 오류 코드를 반환합니다.
설명
COM 시그니처
Textmgr.idl에서:
HRESULT IVsTextLayer::CopyLineText(
[in] long iStartLine,
[in] CharIndex iStartIndex,
[in] long iEndLine,
[in] CharIndex iEndIndex,
[in] LPWSTR pszBuf,
[in, out] long * pcchBuf
);
CopyLineText최대 복사 합니다. cchBuf 문자입니다. 버퍼가 충분히 큰 있지 않은 경우 CopyLineText 반환 BUFFER_E_DEST_TOO_SMALL 및 설정 * 필요한 크기입니다.
참고
pcchBuf유니코드 문자를 바이트 수 없습니다 수가 있습니다.
필요한 크기를 얻으려면 하면 설정할 수 있습니다 pszBuf 에 nullNull 참조(Visual Basic의 경우 Nothing).
.NET Framework 보안
- 직접 실행 호출자의 경우 완전히 신뢰합니다. 이 멤버는 부분적으로 신뢰할 수 있는 코드에서 사용할 수 없습니다. 자세한 내용은 부분 신뢰 코드에서 라이브러리 사용를 참조하세요.