Code: Select all
for constr in App.ActiveDocument.Sketch.Constraints:
if constr.Type == "DistanceX":
constr.Name = "Width"
Code: Select all
for constr in App.ActiveDocument.Sketch.Constraints:
if constr.Type == "DistanceX":
constr.Name = "Width"
Code: Select all
sketch.renameConstraint(constraint_idx, u'new_name')