我写了VBA代码(学校电脑上没.NET)- Sub abc()Dim ucsObj As AcadUCS
- ThisDrawing.SendCommand ("UCS S" & vbCr & "Test" & vbCr)
- Set ucsObj = ThisDrawing.UserCoordinateSystems("test")
- [color=red]ThisDrawing.SendCommand ("n ")[/color]Dim WCSPnt As Variant
- Dim UCSPnt As VariantWCSPnt = ThisDrawing.Utility.GetPoint(, "Enter a point: ")
- UCSPnt = ThisDrawing.Utility.TranslateCoordinates(WCSPnt, acWorld, acUCS, False)
-
- Dim cc As AcadCircle
- Dim r As Double
- r = 100
- Set cc = ThisDrawing.ModelSpace.AddCircle(WCSPnt, r)End Sub
红色的代码看的不爽,lzh741206兄请给改一下. |