cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
johnjohn123
Super User
Super User

How i can set the Default values for a ListBox to be equal to a Choice sharepoint field which allow multiple selection

I have a SharePoint Choice field which allow multiple selection named "Peripheral" , and i want to set the values in this field as options inside the listBox, i tried the following :-

 

uiee.png

 

but i got this error "Ëxpected Text value. ListBox1.Default".. any advice?

3 REPLIES 3
RandyHayes
Super User
Super User

@johnjohn123 

You cannot set the default items of a ListBox in PowerApps.

 

I hope this is helpful for you.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
NOTE: My normal response times will be Mon to Fri from 1 PM to 10 PM UTC (and lots of other times too!)
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!
v-jefferni
Community Support
Community Support

Hi @johnjohn123 ,

 

If you would like to set multiple default selected items for a single Control within a Canvas App, the Combo box is the only choice.

 

Hope this helps.

 

Best regards,

Community Support Team _ Jeffer Ni
If this post helps, then please consider Accept it as the solution to help the other members find it.

Community Support Team _ Jeffer Ni

If this post helps, then please consider Accept it as the solution to help the other members find it.

RandyHayes
Super User
Super User

@v-jefferni 

Actually, it is a little easier to utilize a Gallery to mimic the Listbox control as it will look a lot like it and you can "simulate" the selected items pretty easily.  Combobox doesn't give that same feel.

 

Below is just an example of a component we have made to simulate the listbox and provide default selected items. It's essentially just a Gallery with a Checkbox control in it (checkboxsize is 0).

SimultatedListBox.gif

@johnjohn123 Hopefully this gives you some ideas as well of how to work around your issue.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
NOTE: My normal response times will be Mon to Fri from 1 PM to 10 PM UTC (and lots of other times too!)
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

Really want to show your appreciation? Buy Me A Cup Of Coffee!

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Community Call Conversations

Introducing the Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (4,374)