Hi guys,
im gettin crazy. i ve set up a combobox which uncludes the following items:
["1","2","3","4"]
i want to display the selected combobox items in a textlabel field (Text = combobox.Selected.Value).... but i only get the last selected combobox entry..... how do i get all of them ... ?
Solved! Go to Solution.
The field name dpeends on the data that you're trying to access. For example, imagine that you have "Accounts" table that has "AccountID", "Account Name" and "Company Name" fields. Now let's say that you want to allow the user to select the AccountID. In this case you set the ComboBox.Items = Accounts and then ComboBox.Selected.AccountID will be the value you're looking for. Alternatively, you could assign ComboBox.Items = Accounts.AccountID and in this case the ComboBox.Selected (not the .AccountID!) value will be the value you're looking for. This is why it is often hard to suggest the proper field name without knowing the underlying data structure.
Please also note that In some cases, the field name is automatically assigned. This usually happens when the ComboBox.Items is set to a formula. In those cases the .Result is usually used. I hope this helps you find the proper field name to use in your applciation.
Hello Marco_h,
Please use "SelectedItems" instead of "Selected". Something like the following should work:
Label1.Text=Concat(ComboBox1.SelectedItems, Value&",")
Please note that "Selected" is mostly used in "single selection" mode (ComboBox1.SelectMultiple=false).
"SelectedItems" property however contains all the selected items in "multiple selection" mode. The type of that property is "Table" and therefore I used the "Concat" function in my example.
Push the selected combobox data to a collection then use concatenate to bring them into a single text field. See https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/create-update-collection which should help along with https://powerusers.microsoft.com/t5/Connecting-to-Data/convert-table-column-to-string/td-p/87539. See the attachment.
Hello:
The links above aren't working any more, I have the same issue. I want to get the selected value from a combo box and view some ather filed of that selected value.
If I want to get the selected value from a display list is fairly easy:
LookUp('Orden de trabajo';numero_OT=ot_seleccionada.Selected.Value;nombre_ot)
Where:
'orden de trabajo' is the entity
"ot_seleccionada" is the name of the display list box
"numero_OT" is the name of the field from "orden de trabajo" wich I'm getting from "ot_seleccionada"
nombre_ot is the name of the field I want to see from the select item in "ot_seleccioanda"
How can I do something similar with a combobox?
To put it simple:
From a display list, I can get the selected item and view it in a text field with:
****.selected.value
If a combo box has only one selected item, how can I get the selected value in a text field?
For a ComboBox control in a "Single Select" mode (SelectMultiple=false) the selected item can be retrieved as ComboBox1.Selected
For a ComboBox control in a "Multi Select" mode (SelectMultiple=true) that has only one selected item, it can be retrieved as
First(ComboBox1.SelectedItems)
Does this answer your question?
Hi:
Thanks for the support
I have (SelectMultiple=false)
When I try in a text box, text fill with:
ComboBox1.Selected
I get the following error(translate form spanish):
Property expected text value, but this rule generates record values not compatible.
I've tried also First(ComboBox1.SelectedItems), but same results...
By the way Combobox is getting the data from a "lookup" entity....
Any clue¿?
ComboBox.Selected references the selected item (record). Try ComboBox.Selected.Value
hi @dinusc,
I tried to use Combobox.selected.value. But its giving me error on the text box and not populating what ever i select on combo box.
When i use combobox.selected.Result i was on,y able to get one value populated into thetext box.
Any ideas to fix this would help.
Thanks,
MK
The field name dpeends on the data that you're trying to access. For example, imagine that you have "Accounts" table that has "AccountID", "Account Name" and "Company Name" fields. Now let's say that you want to allow the user to select the AccountID. In this case you set the ComboBox.Items = Accounts and then ComboBox.Selected.AccountID will be the value you're looking for. Alternatively, you could assign ComboBox.Items = Accounts.AccountID and in this case the ComboBox.Selected (not the .AccountID!) value will be the value you're looking for. This is why it is often hard to suggest the proper field name without knowing the underlying data structure.
Please also note that In some cases, the field name is automatically assigned. This usually happens when the ComboBox.Items is set to a formula. In those cases the .Result is usually used. I hope this helps you find the proper field name to use in your applciation.
User | Count |
---|---|
132 | |
127 | |
78 | |
73 | |
70 |
User | Count |
---|---|
207 | |
200 | |
64 | |
63 | |
52 |