Change the element name during runtime

You can dynamically change the displayed name (label) of all elements by using a report. You can specify the names in multiple languages.

Prerequisite

At least one element of the dialog provides the report support.

Procedure

  1. Open a report for editing.

  2. Add the following for each element of the dialog for which you want to dynamically change the display name. The report executed during runtime of the dialog.

    Context.setProperty("Text_box_1.label","This is my new textbox label");

    If you want to change the display names dynamically for multiple languages, enter the code in the following form

    Context.setProperty("mycontrol.label.en","my english label");

    Context.setProperty("mycontrol.label.de","mein deutsches Label");

The names of the elements are now specified in the report that is executed during the runtime of the dialog.

Example

This example shows what the report code looks like to change the displayed element name using a report for English, German and French:

Context.setProperty("32f3f460-fd5b-11e8-1af0-5048494f4e43.label.en","My english label");

Context.setProperty("32f3f460-fd5b-11e8-1af0-5048494f4e43.label.de","Mein deutsches Label");

Context.setProperty("32f3f460-fd5b-11e8-1af0-5048494f4e43.label.fr","Mon étiquette française")