Get# list doesn’t work well

I have a list that stores numbers, which are row numbers of an airtable spreadsheet. When the user selects one entry in a list viewer showing the results rows that contains an input string, I use the index to get the #index position in my list. Sometimes this works fine, but then starts to return the next position. Later works fine, then wrong, …So I don’t know how to fix it. Any help?
Thanks
Lidia

Hi Lidia,

Did you get a chance to read any of the posts I sent you earlier in the week? Did any of them help with this, no?

Yes, I took a look to your code “Searching and filtering” with LocalDB. Your code and my code are equal, I didn’t have to change anything because I’ve already use list to store index, etc. After tracing the problem, I think that the problem is in the list. The listviewer works ok, the getcolumn also works well.


And the last 10 executions worked bad, and now I wanted to show you the bad execution and started to work well, but I know that in five minutes it will work bad again.
In for example Java this happens when you forgot to initialize a variable, but here everything is initialized. So I don’t know how to fix it for ever.
Thanks
Lidia

I have a feeling it might be going back and forth with the screens. Try to display the results in a label on the same screen and see if the same thing happens.

No, is not this, because I print in a label in the same screen the value of the #index of my list of indexes and the value is wrong. The last thing I did is change the the “in list insert at last”+counter by “in list set #index”+counter and now is working. I don’t know if it will continue working for ever or not. If this was the problem, it seems that there is a problem with the implementation of the lists. It seem that you use dynamic memory wrongly. I hope that the “in list set #” is implemented with an array of static memory. So, please tell developers to test lists implementations.
Thank you for your support.
Lidia