79673917

Date: 2025-06-20 20:26:50
Score: 0.5
Natty:
Report link

To properly resolve this issue in Power Apps, where you need a ComboBox on a second form to automatically populate with the same value selected in the ComboBox on the first form, you must use the DefaultSelectedItems property and keep in mind that a ComboBox expects a table (even for a single value), which is why the brackets [] are required.

Consider the following:

ComboBox_Clientes_Form1 → belongs to the first form (it already works and displays customer data).

ComboBox_Clientes_Form2 → must display the same customer in the second form.

Properties

1. Items in both ComboBoxes

Both must have the same list or set of customers as their data source:

Items: ListaClientes

2. DefaultSelectedItems in the ComboBox on the second form

Here's the most important part:

DefaultSelectedItems: [ComboBox_Clientes_Form1.Selected]

If you don't use brackets [], Power Apps throws an error because it expects a table, even if it's a single-record table.

Power Apps treats DefaultSelectedItems as a table of values ​​because a ComboBox can be multi-select. Even if you only want to select one item, you need to encapsulate it in a table (a list of one), hence [ComboBox.Selected].

If the ComboBox is single-select, make sure AllowMultipleSelection is false.

If you're using SubmitForm instead of Patch(), make sure the field is correctly connected to a Lookup DataField field in SharePoint.

Reasons:
  • Long answer (-1):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Carlos Diaz