求修改,vba旋转生成实体
<p>Public Sub createsping()<br/> On Error Resume Next<br/> Dim pt(0 To 2) As Double<br/> pt(0) = 0: pt(1) = 0: pt(2) = 0<br/> If Err Then<br/> Err.Clear<br/> Exit Sub<br/> End If<br/> Dim cir1 As AcadCircle<br/> Dim cir2 As AcadCircle<br/> Dim pnts As Variant<br/> Set cir1 = ThisDrawing.ModelSpace.AddCircle(pt, 5)<br/> Dim p(0 To 2) As Double<br/> Dim t(0 To 2) As Double<br/> p(0) = 10: p(1) = 0: p(2) = 0<br/> t(0) = 10: t(1) = 10: t(2) = 0<br/> </p><p> <br/> cc = ThisDrawing.ModelSpace.AddRegion(cir1)<br/> <br/> <br/> Dim re As Acad3DSolid<br/> Set re = ThisDrawing.ModelSpace.AddRevolvedSolid(cc, p, t, 6.28)</p>
<p>End Sub</p>
<p>始终不能生成实体~~~~~</p>
页:
[1]