Combo box showing <...>

0
I’m using a combo box on a page where its attribute is set in a microflow that triggers a refresh in client. However, after updating, the combo box sometimes displays <...>. The data source is set to “Database” and the selectable objects are provided by a "Microflow". The attribute I’m using belongs to the data view entity. I’ve tried clearing the value before setting it, updating the value via a nanoflow, and setting it in an On Change microflow, but the issue persists. Could you please suggest a solution to resolve this behavior? Thank you in advance.
asked
2 answers
1

Hi Sudarsanam,

The <...> caption is what the Combo Box (Database mode) shows when the selected option can no longer be found in its options list. The widget keeps track of the selected option object, not just the value. When the options list is reloaded with different objects, it can’t find the previous one and shows <...>.

In your case, Refresh in client causes the selectable-objects microflow to run again. If that microflow creates the option objects (for example non-persistable objects), each run returns new objects with new IDs, so the combo box loses its link to the selected option.

How to fix it

  1. Remove “Refresh in client” from the Change object activity, if you only change an attribute of the data view object. Changes to an object the page already shows are sent back to the client automatically. “Refresh in client” mainly forces data sources to reload, and that reload is what causes the problem here.
  2. Return the same objects every time. Let the options microflow retrieve existing (persistable) objects instead of creating new ones. Or set the selectable objects data source to Database (XPath). The objects then keep the same IDs, and the combo box can always find the selected one.
  3. Make sure the value matches exactly. The value you set in the microflow must be identical to the value attribute of one of the options: same text, case, no extra spaces, same number precision. And the option must be in the list the microflow returns at that moment.
  4. Avoid lazy loading with a microflow data source. Mendix advises against it, because only part of the list may be loaded and the selected option may be missing.
  5. Update Data Widgets to the latest version compatible with Studio Pro 10.24, as the combo box receives regular fixes.

If the value you store represents an object anyway, consider using an association instead of a string attribute. The combo box then works directly with the object and doesn’t need to match values.

Kindly accept the answer if it resolves your query.

answered
1

Hi Sudarsanam,


Since the combo box intermittently displays <...> after a refresh, I would first verify that the selected value is still valid and can be resolved against the options returned by the datasource.


Recommended troubleshooting steps


1. Verify the selected value and datasource results

  • Debug the microflow that sets the value and confirm the exact value it assigns.
  • Debug the combo box datasource microflow and confirm that it returns the expected options, including the currently selected value.
  • Verify that the selected value and the values exposed by the datasource use the same type and matching values.

If the selected value is missing from the returned options, correct the datasource or the logic that sets the selection.


2. Check the combo box binding

If the combo box stores a string or integer value, verify that the configured selectable values and target attribute are compatible.

If it uses an association, verify that the selected object belongs to the expected entity and that the association is configured correctly.


3. Check the caption configuration

Verify that the caption attribute or expression is populated for the selected option. If the caption depends on another associated object, check that the required data is available and accessible.


4. Avoid unnecessary refreshes

Make sure the update microflow completes before refreshing the relevant object in the client. If the value is set through a nanoflow, ensure that the update and refresh happen in the correct order.

As a diagnostic test, temporarily remove the additional refresh logic and see whether the issue still occurs. Do not add more refreshes until you identify which object needs refreshing.


5. Test with a simplified configuration

Temporarily use a database datasource with a small, predictable set of options. If the issue disappears, compare that configuration with the original microflow datasource to identify differences in the selected value, returned options, or captions.


Also check the browser console for errors when the combo box displays <...>.


Reference: Mendix Combo Box Documentation


My recommendation: Start by verifying that the selected value set by your microflow matches an option returned by the datasource. This is the first thing I would investigate before changing the refresh logic.


Hope this helps! If you find this answer helpful, please mark it as the accepted answer.

answered