Debutant in need of help : ”The operation select list item cannot accept the arguments: , [*empty-string*], [1]”

Hi, this is my first time ever trying to build an app with zero experience and I am totally stuck !

The goal is to create an app to register memberships (for a sewing activity my charity organizes) by opening a pop up with informations to file out and then those will be stored in a list that you can edit or delete ! I am trying to create a popup asking if you’re really sure you want to delete the client’s infos because i know my collegues and we will have some problemes withous this safety net !

But when I try to say that I DO want to delete the infos, Kodular shows this message

The operation select list item cannot accept the arguments: , [empty-string], [1]

or this one

Select list item: Attempt to get item number 2 of a list of length 1: (“Nom : X Prénom : X Téléphone X Mail : X Adresse : X Notes : X”)

If you could help me out, it would be amazing ! and if any of you has an idea on how to establish a counter for how many time each person visited (to keep track on how many times and when each person came) that would also be great !

Thanks a lot !
TEC2.aia (431.8 KB)

You’re trying to access an empty list


To avoid this, confirm that the tag list isn’t empty by checking
blocks
In Companion, this error may still persist, so I recommend first clearing all tags from the companion

Run this block in your project. This will clear all tags saved on the device and put you in a tag-free mode, whereby all tags will come from the current project without trying to access old tags.

Then


Try this

For this


1 Like

Hi dear,

Welcome to the Kodular community!

Given the very noble purpose, I took the liberty of preparing an intermediate project for you to use as inspiration :blush:

The main changes I made are:

  • Use of RecyclerList (with a schema) instead of ListView (which is not recommended for displaying data like yours)
  • Added a function to count app visits (Ibrahim’s answer is also very valid, and depending on your needs it may even be better than mine in terms of performance)
  • Use of a single Notifier to display all messages, leveraging the CustomChooseDialog ID
  • Added a search bar so you can search for any term

Main blocks

TEC2.aia (569.3 KB)
I added a few comments in the project that might help.


The filter doesn’t do anything for now and is just visual :grin: if you need it, we can try to implement it.

1 Like

That is absolutely amazing and beyond anything I could have done on my own, thank you so so much ! My team is really grateful for the efforts you put in this project and we are so excited to start using it !
I will continue to work on it so that I can get better at this and hopefully one day do things as amazing for other struggling strangers on the internet ! If you ever visit France and want a sewing class, it’s on us :wink:

1 Like

I remain fully available if you need any explanation regarding any specific part.

I wish you a great day, dear!