CRichEditCtx.ScrollPosmethod
Gets/sets the current scroll position of the edit control.
Syntax
PRIVATE PROPERTY CRichEditCtx.ScrollPos () AS .POINT
Parameters
| Name | Description | |
|---|---|---|
pt | A POINT structure which specifies a point in the virtual text space of the document, expressed in pixels. The document will be scrolled until this point is located in the upper-left corner of the edit control window. If you want to change the view such that the upper left corner of the view is two lines down and one character in from the left edge. You would pass a point of (7, 22). The rich edit control checks the x and y coordinates and adjusts them if necessary, so that a complete line is displayed at the top. It also ensures that the text is never completely scrolled off the view rectangle. |
Return value
(GET) A POINT structure containing a point in the virtual text space of the document, expressed in pixels. This point will be the point that is currently located in the upper-left corner of the edit control window.
(SET) This message always returns 1.
Description
Gets/sets the current scroll position of the edit control.
Remarks
The values returned in the POINT structure are 16-bit values (even in the 32-bit wide fields).
Example
(GET) PROPERTY ScrollPos () AS .POINT (SET) PROPERTY ScrollPos (BYREF pt AS .POINT)
Reference
- Defined in AfxNova/CRichEditCtx.inc:1680
- Documented in Windows/WIndows Controls/RichEdit/CRichEditCtx Class.md
- Topic: CRichEditCtx Class