Support

As evidenced by over 30 years of development history, trust-worthy Korean CAD, CADian!

FAQ · 2013.12.11
CADian VBA Sample Code - 5 [ Circle ]
Creates a circle given a center point and radius.

Signature
RetVal = object.AddCircle(Center, Radius)

Object
ModelSpace Collection, PaperSpace Collection, Block
The objects this method applies to.

Center
Variant (three-element array of doubles); input-only
The 3D WCS coordinates specifying the circle""s center.

Radius
Double; input-only
The radius of the circle. Must be a positive number.

RetVal
Circle object
The newly created Circle object.

Remarks
This circle is created on the XY plane of the WCS.

---------------------------------------------------------------

Dim icadDoc As IntelliCAD.Document
Dim icadCircle As IntelliCAD.Circle
Dim cenPt As IntelliCAD.Point

Set icadDoc = ActiveDocument
Set cenPt = Library.CreatePoint(1, 2)

""Add the circle to the .dwg
Set icadCircle = icadDoc.ModelSpace.AddCircle(cenPt, 4)

"" Display the entity
icadCircle.Update

MsgBox "Circle created w/ center point at 1,2."

ThisDocument.ActiveViewport.ZoomExtents

Added to cart.

VIEW CART

Please sign in first.

JOIN