Macro Remove parametric history

From FreeCAD Documentation
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.
This page is a translated version of the page Macro Remove parametric history and the translation is 100% complete.

Remove parametric history

Descripción
Esta macro eliminará toda la asociatividad paramétrica de un objeto, dejándolo como una forma "tonta"

Versión macro : 0.1
Fecha última modificación : 2011-08-01
Versión FreeCAD : All
Descargar : ToolBar Icon
Autor : Yorik
Autor
Yorik
Descargar
ToolBar Icon
Enlace
Versión Macro
0.1
Fecha última modificación
2011-08-01
Versión(es) FreeCAD
All
Acceso directo predeterminado
None
Ver también
None

Descripción

Esta macro eliminará toda la asociatividad paramétrica de un objeto, dejándolo como una forma "tonta"

Antes y después de:

Script

ToolBar Icon

Remove parametric history.FCMacro

originalObject = FreeCAD.ActiveDocument.ActiveObject
newShape = originalObject.Shape.copy()
newName = FreeCAD.ActiveDocument.ActiveObject.Name
FreeCAD.ActiveDocument.removeObject(newName)
newObject = FreeCAD.ActiveDocument.addObject("Part::Feature",newName)
newObject.Shape = newShape