The Trimble Assistant for Tekla side pane in Tekla Structures lets you run the code that the Developer Assistant generates, and save macros directly in Tekla Structures. You can also view logs about
successful execution of the generated code, and about errors when executing the
generated code.
We recommend that you use the
Default environment in Tekla Structures because the Developer Assistant uses profiles from that environment to generate code.
-
In Tekla Structures, open
the Trimble Assistant for Tekla side pane.
- If the Developer Assistant is not already selected, select Developer Assistant from the list of assistants at the top of the chat.
-
Write your prompt.
Example: Generate a
macro that lists all profiles used in the model and then displays them
in a dialog.
The Developer Assistant generates a response that includes a code block, an explanation of
what the macro does, and the source of the information that the Developer Assistant used to generate the code.
After code generation, the
code is editable.
-
To run the generated code as a macro in Tekla Structures, click
Execute code.
If the code execution is successful, the log is shown in a green color
with the message "Done. Check the results in Tekla Structures."
If an error occurs, the Run error log button
appears below the code block. Click Run error log
to show the error log.
-
If needed, edit the code and run it again until the macro works the way
that you want it to.
You can also ask the Developer Assistant to help you refine the code.
-
To save the generated code for future use, save the macro.
-
Click Save macro.
-
In the Name box, enter a name.
-
In the Location box, select the location
where you want to save the file.
-
If you want to add a custom image to the macro, drag an image file
to the Image box, or browse to the image
file.
-
Click
Save.
A confirmation message appears. The code is saved as a macro that can be
started from the Applications &
components catalog.
-
To update the Applications &
components to show the macro, select .