ArrayPolar Method
IntelliCAD 11.1 Object Library | |
ArrayPolar Method | |
See Also |
- NumberOfObjects
- The number of objects in the array.
- IncludedAngle
- The angle to fill in radians, with a positive value specifiyingc ounterclockwise rotation.
- CenterPoint
- A Point object specifying the center point of the polar array.
- PointOnAxis
- An optional point on the axis of rotation.
- RotateObjects
- An optional Boolean variable indicating whether to rotate objects or not. The default is False (no rotation).
DimRotated Object : ArrayPolar Method |
Description
Creates a polar array. If the PointOnAxis is distinct from the CenterPoint, a 3D array is created.
Syntax
Visual Basic |
---|
Public Function ArrayPolar( _ ByVal NumberOfObjects As Integer, _ ByVal IncludedAngle As Double, _ ByVal CenterPoint As Point, _ ByVal PointOnAxis As Point, _ Optional ByVal RotateObjects As Boolean = False _ ) As SelectionSet |
Parameters
- NumberOfObjects
- The number of objects in the array.
- IncludedAngle
- The angle to fill in radians, with a positive value specifiyingc ounterclockwise rotation.
- CenterPoint
- A Point object specifying the center point of the polar array.
- PointOnAxis
- An optional point on the axis of rotation.
- RotateObjects
- An optional Boolean variable indicating whether to rotate objects or not. The default is False (no rotation).
Example
Sub Example_ArrayPolar()
' This example creates a line and a polar array based on that line.
Dim myLine As IntelliCAD.Line
Set myDoc = Application.ActiveDocument
Set myLine = myDoc.ModelSpace.AddLine(Library.CreatePoint(4, 4), Library.CreatePoint(7, 1))
myLine.Update
ThisDocument.Application.ZoomExtents
Dim noOfObjects As Integer
Dim angleToFill As Double
Dim basePt As IntelliCAD.Point
noOfObjects = 6
angleToFill = 4.72 ' 270 degrees
Set basePt = Library.CreatePoint(4, 2, 0)
' Create 6 copies of an object by rotating and copying it about the point (4,2,0).
Dim retObj As Variant
Set retObj = myLine.ArrayPolar(noOfObjects, angleToFill, basePt)
retObj.Update
ThisDocument.Application.ZoomExtents
MsgBox "Polar array constructed."
End Sub
' This example creates a line and a polar array based on that line.
Dim myLine As IntelliCAD.Line
Set myDoc = Application.ActiveDocument
Set myLine = myDoc.ModelSpace.AddLine(Library.CreatePoint(4, 4), Library.CreatePoint(7, 1))
myLine.Update
ThisDocument.Application.ZoomExtents
Dim noOfObjects As Integer
Dim angleToFill As Double
Dim basePt As IntelliCAD.Point
noOfObjects = 6
angleToFill = 4.72 ' 270 degrees
Set basePt = Library.CreatePoint(4, 2, 0)
' Create 6 copies of an object by rotating and copying it about the point (4,2,0).
Dim retObj As Variant
Set retObj = myLine.ArrayPolar(noOfObjects, angleToFill, basePt)
retObj.Update
ThisDocument.Application.ZoomExtents
MsgBox "Polar array constructed."
End Sub