version 6.0
DR GET POLYGON VERTEX (area; scope; number; vertexH; vertexV)
| Parameter | Type | Description | |
| area | Longint | 4D Draw area | |
| scope | Longint | -1=First polygon in the document | |
| 0=Selected | |||
| >0=Object ID | |||
| number | Integer | Number of vertex to edit | |
| vertexH | Number | Horizontal position | |
| vertexV | Number | Vertical position |
Description
The command DR GET POLYGON VERTEX returns into the vertexH and vertexV variables the position of the vertex specified by number for the polygon in area described by scope.
If scope equals -1, the command returns coordinates for the first polygon in the document.
If scope equals 0, the command returns coordinates for the first polygon in the current selection.
If scope is greater than 0, it must be equal to a specific polygon's object ID; the command returns that polygon's coordinates. If the object does not exist, DR GET POLYGON VERTEX does nothing, and DR Error returns error number 2. If the object described by scope is not a polygon, DR GET POLYGON VERTEX returns -32000 for vertexH and vertexV, and DR Error returns error number 47.
number is the number of the vertex within the polygon. Vertices are numbered in the order in which they were created. If number exceeds the number of vertices in the polygon, DR GET POLYGON VERTEX does nothing, and DR Error returns error number 49.
vertexH and vertexV are the coordinates for the vertex, and are expressed in base units. Use the DR Base to scale function to convert from base units to scale units. vertexH and vertexV are returned as offsets from the current origin.
Positive values indicate a position below or to the right of the origin.
Negative values indicate a position above or to the left of the origin.
Example
See the example for the DR SET POLYGON VERTEX command.
See Also