|
|
|
|
|
<Word Processing>.Position (Function) In french: <Traitement de texte>.Positionne Triggers the scroll of Word Processing control in order for the requested text to be entirely displayed. You have the ability to define the position of this text in relation to the control borders. // Displays the seection if it was not visible WP_MyDoc.Position() Â // Positions the selection at the top of control WP_MyDoc.Position(0) Â // Positions the selection at the bottom of control horizontally centered WP_MyDoc.Position(100, 50) Â // Positions the document section found between the characters 123 and 158 // at 30% of the remaining space in height and at 40% in width WP_MyDoc.Position(123, 158, 30, 40)
Syntax
Displaying the selected text at the requested position Hide the details
<Word Processing control>.SetPosition([<Vertical positioning> [, <Horizontal positioning>]])
<Word Processing control>: Control name Name of the Word Processing control to use. <Vertical positioning>: Optional integer Vertical position of selected text. This position corresponds to the percentage in height of remaining space (once the height of selected text is deducted) in the Word Processing control. If this parameter is not specified (or if it corresponds to the dpDefault constant), the function will trigger the minimum scroll to display the selected text. Corresponds to: - value included between 0 and 100. For example:
- one of the following constants:
| | dpBottom | The selected text is displayed at the bottom of the Word Processing control. | dpCenter | The selected text is displayed in the vertical center of the Word Processing control. | dpDefault (Default value) | Minimum vertical scroll in order for the selected text to be displayed in the Word Processing control. | dpTop | The selected text is displayed at the top of Word Processing control. |
<Horizontal positioning>: Optional integer Horizontal position of selected text. This position corresponds to the percentage in width of remaining space (once the width of selected text is deducted) in the Word Processing control. If this parameter is not specified (or if it corresponds to the dpDefault constant), the function will trigger the minimum scroll to display the selected text. Corresponds to: - value included between 0 and 100. Some examples:
- one of the following constants:
| | dpCenter | The selected text is displayed in the horizontal center of Word Processing control. | dpDefault (Default value) | Minimum horizontal scroll in order for the selected text to be displayed. | dpLeft | The selected text is displayed on the left of Word Processing control. | dpRight | The selected text is displayed on the right of Word Processing control. |
Displaying a text section at the requested position Hide the details
<Word Processing control>.SetPosition(<Start of text to display> , <End of text to display> , <Vertical positioning> [, <Horizontal positioning>])
<Word Processing control>: Control name Name of the Word Processing control to use. <Start of text to display>: Integer Start position (in number of characters) of text section to display. <End of text to display>: Integer End position (in number of characters) of text section to display. <Vertical positioning>: Optional integer Vertical position of selected text. This position corresponds to the percentage in height of remaining space (once the height of text section is deducted) in the Word Processing control. If this parameter is not specified (or if it corresponds to the dpDefault constant), the function will trigger the minimum scroll to display the selected text. Corresponds to: - value included between 0 and 100. For example:
- one of the following constants:
| | dpBottom | The text section is displayed at the bottom of the Word Processing control. | dpCenter | The text section is displayed in the vertical center of the Word Processing control. | dpDefault (Default value) | Minimum vertical scroll in order for the text section to be displayed in the Word Processing control. | dpTop | The text section is displayed at the top of the Word Processing control. |
<Horizontal positioning>: Optional integer Horizontal position of selected text. This position corresponds to the percentage in width of remaining space (once the width of text section is deducted) in the Word Processing control. If this parameter is not specified (or if it corresponds to the dpDefault constant), the function will trigger the minimum scroll to display the selected text. Corresponds to: - value included between 0 and 100.:
- one of the following constants:
| | dpCenter | The text section is displayed in the horizontal center of the Word Processing control. | dpDefault (Default value) | Minimum horizontal scroll in order for the text section to be displayed. | dpLeft | The text section is displayed on the left of the Word Processing control. | dpRight | The text section is displayed on the right of the Word Processing control. |
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|