Initialize a ComboBox
-
Patrick
Has successfully completed the online course Introduction
2 years ago #36590I am not able to initialize a ComboBox with values when starting an application. We use version 6.5.153-LTS.148. What am I doing wrong?
I created a SQLite table and stored two values. Then I created a ComboBox in the UIDesigner and put an Item in the content. I activated “itemsTemplate” for the ComboBox. In the ProcessDesigner I placed a data service after an onInit event and mapped the table to the key-value pair of the items. Unfortunately, the main entity cannot be mapped. See screenshots!
Attachments:
You must be logged in to view attached files.Jennifer Häfner
Has successfully completed the online course Intermediate (200)
Has successfully completed the online course Advanced (300)
Has successfully completed the online course Basics (100)
Has successfully completed the online course Advanced (310)
Has successfully completed the online course Advanced (320)
Has successfully completed the Intermediate Certification
Has successfully completed the Advanced Certification
2 years ago #36600::Yes, the data source is an easy way of binding that can be configured in the UI Designer and works for Connectors and Business Objects.
If you’re using an SQL connector, you can define your connector, the respective call and the output in the data source. Then, for text/key, define the data source as binding for the property (as you have already done).
Now you still need to tell the app when the Connector/BO should be executed. So, drag and drop the property ‘data source’ to your story in the Process Designer (hover the mouse over the title ‘Data Source’ and you will see an indicator that it can be dragged). A shape will be created automatically that executes the Connector/BO and defines the mapping in the output.
This completes the mapping process.
Attachments:
You must be logged in to view attached files.Jennifer Häfner
Has successfully completed the online course Intermediate (200)
Has successfully completed the online course Advanced (300)
Has successfully completed the online course Basics (100)
Has successfully completed the online course Advanced (310)
Has successfully completed the online course Advanced (320)
Has successfully completed the Intermediate Certification
Has successfully completed the Advanced Certification
2 years ago #36596::Hi Patrick,
This is a bug in the Data Services mapping that has been fixed in Simplifier 7.0.
If an update is not an option for you, you can create an SQL connector for the data scheme and create a connector call to select all items. In the process designer, use this connector call to map the items to the combobox (the datatype of the connector output and the datatype configured in the combobox have to match, though).
Patrick
Has successfully completed the online course Introduction
2 years ago #36599::Hi Jennifer,
we’ve already tested a SQL connector but it was the same issue. Unfortunately, an update is currently not an option for us.
However, we noticed that since our last update there is a new “shape”: the “data source” in the UIDesigner. If we enter the entity set in the data source additionally and bind the parameters (key, value) there, then the mapping in the process designer works.
But there is no onInit event in the UIDesigner binding, so we have to map the data twice:
1. in the UIDesigner via data source and
2. in the ProcessDesigner via DataService after an onInit event.That seems to be a very uncomfortable solution. Do you have a better idea?
You must be logged in to reply to this topic.