ITextRangeProvider::ScrollIntoView method (uiautomationcore.h)

Causes the text control to scroll vertically until the text range is visible in the viewport.

Syntax

HRESULT ScrollIntoView(
  [in] BOOL alignToTop
);

Parameters

[in] alignToTop

Type: BOOL

TRUE if the text control should be scrolled so the text range is flush with the top of the viewport; FALSE if it should be flush with the bottom of the viewport.

Return value

Type: HRESULT

If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.

Remarks

ITextRangeProvider::ScrollIntoView respects both hidden and visible text.

If the text range is hidden, the text control will scroll only if the hidden text has an anchor in the viewport.

Requirements

   
Minimum supported client Windows XP [desktop apps | UWP apps]
Minimum supported server Windows Server 2003 [desktop apps | UWP apps]
Target Platform Windows
Header uiautomationcore.h (include UIAutomation.h)

See also

Conceptual

ITextProvider

ITextRangeProvider

Reference

UI Automation Providers Overview