version 6.0
DR SET TEXT (area; scope; characters)
| Parameter | Type | Description | |
| area | Longint | 4D Draw area | |
| scope | Longint | -3 = Selected characters, -1 = All, | |
| 0 = Selected objects, >0 = Object ID | |||
| characters | Text | Characters to set |
Description
The command DR SET TEXT fills the text objects in area described by scope with characters.
If scope equals -3, the command replaces the highlighted text of the selected text object with characters. If the insertion point is between characters, DR SET TEXT inserts characters at the insertion point.
If scope equals -1, the command replaces the text of the first object of the document.
If scope equals 0, the command replaces the text in the first selected object.
If scope is greater than 0, it must be equal to the ID of a specific text object; DR SET TEXT replaces that object's text. If the object does not exist, DR SET TEXT does nothing, and DR Error returns error number 2.
If the object described by scope is not a text object, DR SET TEXT does nothing, and DR Error returns error number 47.
Example
The following example makes the characters in the process variable vText the text for the selected text objects.
DR SET TEXT (Area;0;vText)
See Also