In this task you will learn how to make a small and simple change of the objectUI configuration, by modifying the default label just for the current dialog box. In this example we choose the Description field of the Edit workstate dialog box in the EdAdmin4 application, defined in the EdAdmin4_Config.xml configuration file. We will rename it to Notes. |
You will be able to perform this task only if: •You already opened the edadmin4_config.xml file as explained in TASK: Open for editing one or more files with objectUI elements ordered the view as explained in TASK: Display an ordered view of objectUI elements, located the editWorkstate objectUI and expanded its Description attribute. |
1.In the Description field definition in editWorkstate objectUI, defined in the EdAdmin4_Config.xml configuration file, add a new content highlighted below (respect the characters case): <attribute name="description"> <ui mode="Normal" label="Notes"> <template kind="MultiLineString" useSpellChecker="yes" xmlns="http://www.teradp.com/schemas/GN4/1/XmlSchemaExt.xsd"> <objectUI> <web maxRows="4"/> </objectUI> </template> </ui> </attribute> 2.Save changes and import them in database as explained in TASK: Save changes and import them in database. 3.Close and run again EdAdmin4 and reopen the Edit workstate dialog box as explained in TASK: Get to know the Workstate entry dialog and recognize its fields. 4.Notice the changes in the dialog box: now, the Description field is now named Notes. As you can clearly see, after you added the label property with an appropriate value, it overrides the default naming, and it acts only on the current dialog box. Conclusions It is rather simple to change the naming on one dialog box. What if you need to do it on all dialog boxes? Then, it is better to do it by changing the default naming convention, defined in the string files, described in the Modifying Strings chapter. Note: if you are tempted to use a global find and replace, resist to the temptation - for many terms, there are too many different places they are used that is it rather difficult to make sure you will not break the files! More reading |