|
发表于 2002-9-24 14:12:00
|
显示全部楼层
谢谢斑竹上次的指教,在下试了几次但没有成功
我通过以下代码可以实现一个图形拷贝到另一个图形
,但对一个具体的图层好象行不通
Private Sub CommandButton6_Click()
Dim str As String, I As Integer, j As Integer
Dim Myss As AcadSelectionSet
Dim Doc1 As AcadDocument, Doc2 As AcadDocument
Set Doc1 = ThisDrawing.Application.Documents("Drawing1.dwg")
Set Doc2 = ThisDrawing.Application.Documents("Drawing2.dwg")
Dim pnmin As Variant, pnmax As Variant
Dim pn1(0 To 2) As Double, pn2(0 To 2) As Double
Me.Hide
ThisDrawing.Application.Documents("Drawing1.dwg").SendCommand Chr(3) + Chr(3) + "._copyclip all" + Chr(32) + Chr(32) ' str + Chr(59)
ThisDrawing.Application.Documents("Drawing2.dwg").SendCommand Chr(3) + Chr(3) + ".__ _pasteorig "
Me.Show
End Sub |
|