From e9b4201fe18a81a107ba5baba9f8777472aea78c Mon Sep 17 00:00:00 2001 From: ebrahimraeyat Date: Sun, 23 Aug 2020 10:18:31 +0430 Subject: [PATCH] ChangeProfile don't remove sketch profile --- fFeatures.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/fFeatures.py b/fFeatures.py index b769794..0751f85 100644 --- a/fFeatures.py +++ b/fFeatures.py @@ -511,7 +511,10 @@ def changeProfile(self): name=FB.Profile.Name FB.Profile=profile FB.Proxy.redraw(FB) - FreeCAD.ActiveDocument.removeObject(name) + if self.SType == '': + profile.ViewObject.Visibility = False + else: + FreeCAD.ActiveDocument.removeObject(name) FreeCAD.ActiveDocument.recompute() FreeCAD.ActiveDocument.recompute() else: