cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
southafrican
Frequent Visitor

ComboBox SelectedItems

Hello 

 

I've got a gallery and 3 ComboBox's I'm trying to Filter the gallery through these ComboBox's.

 

ComboBox 1

A list on Names 

 

ComboBox 2

Another List of names, however, they should be dependent of the first list

 

Now the problem I'm getting is that when I put 'SelectedItems' the error that gets returned is "Invalid Schema, expected a one-column table"

 

How do I stop this from happening? 

 

error.PNG

1 ACCEPTED SOLUTION

Accepted Solutions
chrisog
Responsive Resident
Responsive Resident

Hi @southafrican,

 

The way ComboBoxes work, due to their ability to select multiple values, is that their SelectedItems value is actually treated as a table.

 

In addition to this, the SelectedItems property refers to a row in a table, not necessarily just an individual value.

 

If you change it to ComboBox1.SelectedItems.ColumnName it will refer to solely that column. In addition, if you are selecting only 1 value from the combobox, it is still treated as a non-record table value using the SelectedItems property.

 

To avoid this, use ComboBox1.Selected.ColumnName. This appears to only select 1 single row value, and you can then specify which column to refer to.

View solution in original post

1 REPLY 1
chrisog
Responsive Resident
Responsive Resident

Hi @southafrican,

 

The way ComboBoxes work, due to their ability to select multiple values, is that their SelectedItems value is actually treated as a table.

 

In addition to this, the SelectedItems property refers to a row in a table, not necessarily just an individual value.

 

If you change it to ComboBox1.SelectedItems.ColumnName it will refer to solely that column. In addition, if you are selecting only 1 value from the combobox, it is still treated as a non-record table value using the SelectedItems property.

 

To avoid this, use ComboBox1.Selected.ColumnName. This appears to only select 1 single row value, and you can then specify which column to refer to.

View solution in original post

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

PA Community Call

Power Apps Community Call

Next call is happening on April 21st at 8a PST.

MBAS Carousel

Sign up for our May 4th event!

May the fourth be with you, join us online!

secondImage

Experience what’s next for Power Apps

See the latest Power Apps innovations, updates, and demos from the Microsoft Business Applications Launch Event.

Top Solution Authors
Top Kudoed Authors
Users online (52,266)