VBA的问题,请教各位高手!
我用VBA做了个窗体,上面有个BUTTON,目的是点击改按钮在图上花直线,但每次点击都出错,说AUTO CAD主窗体不可见,请问如何解决? 这是按钮的点击事件,没有问题的:Private Sub CommandButton1_Click()
Dim P1(2) As Double
Dim P2(2) As Double
Dim Line As AcadLine
P1(0) = 5: P1(1) = 5
P2(0) = 25: P2(1) = 50
Set Line = ThisDrawing.ModelSpace.AddLine(P1, P2)
ThisDrawing.Regen acActiveViewport
End Sub
页:
[1]