SetVertices [Polyline3D, Polygon3D]
SetVertices sets the X, Y, and Z coordinates of the vertices for 3D polylines or the 3D polygons.
Syntax
object.SetVertices( VerticesXY, VerticesZ, PolyCounts )
Parameter |
Type |
Required/ Optional |
Default |
Description |
VerticesXY |
Array of Doubles |
Required |
This provides the X and Y coordinates of the new vertices (first entry is the X coordinate of the first vertex, second entry is the Y coordinate of the first vertex, third entry is the X coordinate of the second vertex, etc.). Applicable to 3D polylines and 3D polygons. |
|
VerticesZ |
Array of Doubles |
Required |
This provides the Z coordinates. Applicable to 3D polylines and 3D polygons. |
|
PolyCounts |
Array of Longs |
Optional |
|
This provides the number of vertices in each ring of the 3D polygon. This parameter is required when using SetVertices on a Polygon3D object. This parameter is not used for Polyline3D object. |
Example
This example demonstrates how to set the XY and Z coordinates for vertices and ring counts for a 3D polygon.
Dim Vertices(3) As Double
Vertices(0) = 4.5
Vertices(1) = 4.3
Vertices(2) = 7.8
Vertices(3) = 0.2
Dim VerticesZ(1) As Double
VerticesZ(0) = 19.6
VerticesZ(1) = -3.14
Dim Counts(0) As Long
PolyCounts(0) = 2
polygon3d.SetVertices(VerticesXY, VerticesZ, PolyCounts)
Used by: Polygon3D object, Polyline3D object