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

Combobox Default Selected Items

Hi,

 

I have created an app which has the data source as 2 separate SharePoint lists on different sites.

I have a new mode form which collects information from one of the sharepoint lists and saves it to the other sharepoint list via a comobobox and concat the values to a multiline text field:

Left(Concat(ComboBox4.SelectedItems, 'Name of information asset'&"|"),Len(Concat(ComboBox4.SelectedItems, 'Name of information asset'&"|"))-1)

 

This then populates another column of the sharepoint list with the ID from the combobox selected item:

Left(Concat(ComboBox4.SelectedItems, ID&";"),Len(Concat(ComboBox4.SelectedItems, ID&";"))-1)

 

When on edit mode, I have managed to create a combobox where the default selected items is populated from a gallery which splits the multiline text field:

RenameColumns(Gallery2.AllItems,"Result","Name_x0020_of_x0020_information_")

 

However, the defaultselecteditems is not populating the ID for the other column although it recognises there are default selected values. I am getting the ";" for the amount of default selected values that there are, along with the ID of any new selected items.

Left(Concat(ComboBox1.SelectedItems, ID&";"),Len(Concat(ComboBox1.SelectedItems, ID&";"))-1)

 

I just need to bring back the ID of the default selected items.

 

Thanks

1 REPLY 1
v-bofeng-msft
Community Support
Community Support

Hi @BSahota :

Could you tell me:

  • What is the Gallery2's Items property?
  • What is the ComboBox1's items propety?

Because of the lack of information, I cannot determine what caused the problem. I have the following suggestions:
I suggest that you do not use 

 

RenameColumns(Gallery2.AllItems,"Result","Name_x0020_of_x0020_information_")

 

as the default property of the combobox. Because the data structure of Gallery2.AllItems is different from the data structure of the data source of Gallery2, it also contains the data information of the controls in the Gallery2.Instead,you can try:

 

Filter(YourComboBox1DataSource,ID in Gallery2.AllItems.ID)

 

Best Regards,

Bof

 

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

MBAS Attendee Badge

Claim Your Badge & Digital Swag!

Check out how to claim yours today!

secondImage

Are Your Ready?

Test your skills now with the Cloud Skill Challenge.

secondImage

Demo Extravaganza is Back!

We are excited to announce that Demo Extravaganza for 2021 has started!

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

Top Solution Authors
Top Kudoed Authors
Users online (73,579)