cancel
Showing results for 
Search instead for 
Did you mean: 

Multiple Selection in ListPicker - Could Someone Help Me?

NoGu
Explorer
0 Kudos
167

Dear community,

I am using the ListPicker tool to select multiple texts from a list. How should I configure it so that all the selected texts are saved when I save the data?

What would you recommend?

View Entire Topic
bill_froelich
Product and Topic Expert
Product and Topic Expert
0 Kudos

It will depend on your use case.  When you say you want to save all selected texts from the multiple selection list picker what does that mean?  Are you wanting to concatenate all the values into a string?  Are you wanting to create one record per selected text?  What does your service expect for how the data is structured when saving?

Can you please elaborate on your scenario?  Thanks

NoGu
Explorer
0 Kudos

I have certain data in a ListPicker, for example: {1 A, 2 B, 3 C ,4 D, 5 F, 6 G,} I select (A, B, and F,) and then click the save button. I get the save message, but when I check the details page, it only shows the A value. I also check the database, and it only saves the A value. However, I need to see and save the selected values (A, B, and F). I’ve tried several configurations, but it keeps saving only one value. I tried setting up a rule, but I’m not sure where to place it. What else should I do?

bill_froelich
Product and Topic Expert
Product and Topic Expert
0 Kudos
It all goes back to this question.What does your service expect for how the data is structured when saving?
NoGu
Explorer
0 Kudos
In answer to the last question, I am using the key-value tool to view the data. i only need to view and save, it does not have a defined structure. How can I achieve this?
bill_froelich
Product and Topic Expert
Product and Topic Expert
0 Kudos
Your Save button will most likely be calling CreateEntity or UpdateEntity and setting the properties like in your screen shot. If you only have one property and are intending to store multiple values in that one property you need to decide how you will structure the data you are saving. If your Odata service has a parent / child structure where your multiple values are stored as multiple child records for the parent then you need to have a rule to loop over the multiple return values and call create/update/delete the child records based on the selection. It all depends on your Odata service structure and what you are trying to achieve when saving the data.
NoGu
Explorer
0 Kudos
excuse me where should I place the rule, maybe you have an example you could share with me?