Reordering a local data source in a data list viewer

Hello,

I’m trying to create a diary with the local data source and present it with the data list viewer component.
The problem is when I add a new row to this data source the new row is presented last.
I want new rows to be first and the old ones to go to the bottom of the list.
I know it is possible to do it with airtable / spreadsheet but those two aren’t good for my purpose.

is there a way to do it?
Thanks in advance!

Hi,

the Data Viewer component displays data in the order in which it is located in the Data Source component. This means that you need to fill in the Data Source correctly. This problem can be solved, but I am afraid that its solution will not be as good as you expect. Why? Try it and see for yourself.

1 Like

Can you explain how to do it, please?

thank you!

Base example scrLocalDBFilteredRecords in https://x.thunkable.com/projects/5d70f93f8a62b4079eedaff2/project/properties/designer/

In this example, data for Data Viewer is taken from Local DB. But in your case, you need to take the data from List, because this will allow you to add entries to the top of the list. The algorithm will be as follows:

  1. Add data to the list of objects

  2. Copy data from the list of objects to Data Source