User talk:Catman: Difference between revisions

From FreeCAD Documentation
(Created page with "talk page creation.")
 
No edit summary
Line 1: Line 1:
I would propose to add a small chapter to address that although edit fields can not be automatically filled in (FC 0.19), this could be acieved with an own macro.
talk page creation.

As a starting point to test this from the Python Console, this Macro shows the principle
<source>
>>> p = App.ActiveDocument.Page
>>> t = p.Template
>>> et = t.EditableTexts
>>> et["FC-Title"] = "The title of my page"
>>> t.EditableTexts = et
</source>

Revision as of 16:26, 27 July 2020

I would propose to add a small chapter to address that although edit fields can not be automatically filled in (FC 0.19), this could be acieved with an own macro.

As a starting point to test this from the Python Console, this Macro shows the principle

>>> p = App.ActiveDocument.Page
>>> t = p.Template
>>> et = t.EditableTexts
>>> et["FC-Title"] = "The title of my page"
>>> t.EditableTexts = et