我想找到一个BlockReference 然后更改它的NAME ,可到了最后一句总报未找到主键,魏森么呢? Dim InsPoint(0 To 2) As Double Dim NewEnt As AcadBlockReference For Each Ent In ThisDrawing.ModelSpace If Ent.ObjectName = "AcDbBlockReference" Then Select Case Ent.Name 'EffectiveName Case "Motor_Cable" Set NewEnt = Ent.Copy Dim point1(0 To 2) As Double point1(0) = 2: point1(1) = 1: point1(2) = 0 NewEnt.InsertionPoint = point1 End Select End If Next NewEnt.Name = "MotorAAA" '这里报错 End Sub 谢谢!! |