Code Generator allows you to automatically generate and assign UserName, PartNumber and Description according to variables related to the model, so that the edit of the model even the Name, PartNumber and Description will be updated to the new value.
In the upper left there are four icons to load and save a configuration, set the current rules as defaults and remove any predefined settings, just below four text fields in which to write the data generation rules, while on the left the buttons with the label, which when pressed show a preview of the assigned value.
at the bottom of dialog box, there are two tabs:
Variables Tab, defines variables to be used to compose the User Name, PartName and Description.
SM_Unfoldreturns the L and W dimension of the unfolded sheet metal part
CustomData Tab, which defines the CustomData to add to the element and how to generate them.
Example of custom data get from expressions.
For edit the Code Generator, right clic on the part and select Open Codification dialog…
Example of construction of user name, part number and description.