hello I use listview image and text with airtable. I try to create a search. I manage to find the name (I miss the image) and when I click on it I do not go to the name I have chosen.thank you
I work with airtable, when I write in the search I have the requested data (if I delete clear list it does not work), but when I click on the data find when I click on it (so listview image and text click ) I don’t get the requested item
If I don’t know what kind of data you have and how you store them I can’t help you.
I need to know what is in the variable to check an error
Explain also which is your goal?
Probably your steps could be :
Is the work flow correct?
I am making a currency converter i am using airtable which is loaded by initialized screen then with listview image and text, when i click on it i but the currency value on a button then by writing the amount i get the result. As there is a lot of currency, I wanted to create a search, with "on changed text I get the result, but it’s when I click on it that I had a problem. Now with the last image, there has an error when I click on image and text without the search.
Ok. You want to convert a currency. Show me which is in listview. All the currencies? And where is the value to convert .
So it doesn’t work if gets error show the text error too
no the error occurs when I click directly on the currency flag and not in search
and in your variable , so I can help you
Now I show some hint for code
This code running in less than 1 sec , why you want to add items to a listview (first for each) and then clear them to show other item? You have to work with variables and use only the last for each to add items in listview . All will work better and fast.
If I read your code correctly after digit on letter in the textbox you will see in list view only the items from global SearchList. Right?
In search list there are only the items that contains text search, so probably the index of the item in device isn’t in the same position of the item in SearchList
But I have to see what you store in global device and other variable.
Why two listview with the same values?
And also I think you can delete this block in the other screenshot
After search you haven’t to use the position in the list device but the device name to find is index in the main list device (use the block index in list thing) . With this index you will find the country in the main list pays
your when textbox on text changed, i dont think you have constructed properly… please tell us how do you store the image, title and text items in global lists…
by deleting what you crossed out I still have the same thing, just the motto.
on the other hand if I don’t go in the search and I click on an image or motto, I have an error message which is: Select list item: Attempt to get item number 1 of a list of length 0: ()
Note: You will not see another error reported for 5 seconds.
Ref this topic for how to create custom search bar for list view with image. Already multiple answers are there