
Private Sub CommandButton2_Click() '查找点和面
Dim productDocument1 As PartDocument '或ProductDocument
Set productDocument1 = CATIA.ActiveDocument
Set selection1 = productDocument1.Selection
If (PointCheck.Value = flase And PlaneCheck.Value = True) Then
selection1.Search "CATPrtSearch.Plane,all"
End If
If (PointCheck.Value = True And PlaneCheck.Value = False) Then
selection1.Search "CATPrtSearch.Point,all"
End If
If (PointCheck.Value = True And PlaneCheck.Value = True) Then
selection1.Search "(CATPrtSearch.Plane+CATPrtSearch.Point),all"
End If
End Sub
Set Label = UserForm3.Controls.Add("Forms.Label.1")'要用具体的userfom1,2,3这种,不能用userform
Label.Caption = "ffffff"
Label.Left = 0
Label.Font.Size = 20
Label.Top = 7.5
Label.Width = 80
Label.Height = 30
CATIA.Visible = False
免责声明:本文系网络转载或改编,未找到原创作者,版权归原作者所有。如涉及版权,请联系删