Compartir a través de


IVsTextView.SetScrollPosition(Int32, Int32) Method

Definition

Sets the core text editor's scroll bar settings for the specified scroll bar.

public:
 int SetScrollPosition(int iBar, int iFirstVisibleUnit);
public:
 int SetScrollPosition(int iBar, int iFirstVisibleUnit);
int SetScrollPosition(int iBar, int iFirstVisibleUnit);
public int SetScrollPosition (int iBar, int iFirstVisibleUnit);
abstract member SetScrollPosition : int * int -> int
Public Function SetScrollPosition (iBar As Integer, iFirstVisibleUnit As Integer) As Integer

Parameters

iBar
Int32

[in] Specifies a horizontal or vertical scroll bar. Values may be either SB_HORZ or SB_VERT. For more information, see GetScrollInfo in the Platform SDK.

iFirstVisibleUnit
Int32

[in] First visible unit for the scroll bar.

Returns

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

Remarks

COM Signature

From textmgr.idl:

HRESULT IVsTextView::SetScrollPosition(  
   [in] long iBar,   
   [in] long iFirstVisibleUnit  
);  

Applies to