309 views
in Embedded Wizard Studio by
Hi All,

How to select all items/multiple items in a vertical list.

1 Answer

0 votes
by

Hello,

the Vertical List manages single selection only. However, you can implement multiple selection too. In such case:

1. Don't use the selection functionality of the list itself.

2. Instead, manage the selection status in each item as a bool property. This means, in your item class add a property and name it e.g. Selected. Ensure the property is of bool type.

3. Implement the properties onset method. The implementation should update the appearance of the item depending on whether it is selected or not,

4. When loading items, query the selection status of the respective item and initialize the selection property accordingly. For example:

5. When the user interacts with the application and the selection of an item is changed, you modify only the data in your storage and then you trigger the list reload the respective item. Consequently the item is reloaded showing the its selection status.

I hope it helps you further.

Best regards

Paul Banach

by
Could you please explain me with an example.
by

Hello,

see the attachment below. It contains an example created according to the above instructions. When you start the application in Prototyper you can tap on the list items and the items toggle their selection. Please remember: the list component does not manage any list data storage. It is just a view. It's up to you how the list data is stored.

Embedded Wizard 10.00 or newer project: multiple-selection-vertical-list

Best regards

Paul Banach

Ask Embedded Wizard

Welcome to the question and answer site for Embedded Wizard users and UI developers.

Ask your question and receive answers from the Embedded Wizard support team or from other members of the community!

Embedded Wizard Website | Privacy Policy | Imprint

...