While Not finished point3D = ThisDrawing.Utility.GetPoint(, "click on next point or red circle to finish!") If Sqr(point3D(0) ^ 2 + point3D(1) ^ 2 + point3D(2) ^ 2) < circleradius Then finshed = True outercircle(0).Delete ThisDrawing.Regen acActiveViewport Else numberofelements = numberofelements + 3 ReDim Preserve polyarray(0 To numberofelements) polyarray(numberofelements - 2) = point3D(0) polyarray(numberofelements - 1) = point3D(1) polyarray(numberofelements) = point3D(2) Set newpoint = ThisDrawing.ModelSpace.AddPoint(point3D) If numberofelements > 2 Then redrawpolyline End If Wend 各位高手,这是绘制图形并填充图形VBA代码的一部分,小弟通过逐步调试发现程序无法跳出该循环,请教各位高手WHILE。。。WEND语句怎样在符合条件后跳出! |