Variables & Constants

This page provides example code for working with Variables & Constants in the Integration Theme.

For Variables & Constants to be accessed via the API, they must be listed in the <permissions> block of DriveWorksConfigUser.xml

For full configuration guidance, see Integration Theme Settings in DriveWorks Pro Help.

Get all Variables

This example displays all of the Variables for a Specification with their values in a table.

Variables for:

Name Value

Get all Constants

This example displays all of the Constants for a Specification with their values in a table.

Constants for:

Name Value

Update a Constant

This example shows how Constant values can be updated via the API.

It uses the first Constant of the configured Project (if Constants are available).

Note: to allow a Constant to be edited by users, it must be granted specific edit permissions.
These are configured per Team, using the canEdit attribute in <permissions> block of DriveWorksConfigUser.xml

See Integration Theme Settings in DriveWorks Pro Help for more details.