rendered paste bodySub main()
Set swApp = Application.SldWorks
Set Part = swApp.ActiveDoc
Set SelMgr = Part.SelectionManager
swApp.ActiveDoc.ActiveView.FrameState = 1
If OptionButton1 = True Then
boolstatus = Part.Extension.SelectByID2("ekamutteri-1@kp1", "COMPONENT", 0, 0, 0, False, 0, Nothing, 0)
Part.ShowComponent2
boolstatus = Part.Extension.SelectByID2("ekaruuvi-2@kp1", "COMPONENT", 0, 0, 0, False, 0, Nothing, 0)
Part.ShowComponent2
Part.ClearSelection2 True
Else
boolstatus = Part.Extension.SelectByID2("ekaruuvi-2@kp1", "COMPONENT", 0, 0, 0, False, 0, Nothing, 0)
Part.HideComponent2
boolstatus = Part.Extension.SelectByID2("ekamutteri-1@kp1", "COMPONENT", 0, 0, 0, False, 0, Nothing, 0)
Part.HideComponent2
Part.ClearSelection2 True
End If
End Sub