Cannot get 1 item from table csv to label

I am try to retrieve item from row csv that I created

and this is the result

when I put index for every item, guess what error I am receive
please help meee


You should simply append a row to the existing file, not a table......

1 Like

Like so:

1 Like

It is working now. Thank you very much, really appreciate this. Took me hours to figure it out

If you just want to store the data (and you don't need it to be in a csv file), you can use TinyDB. There you can directly save the table.

If you are going to work with a CSV, I also recommend that when you start the screen, you convert the CSV into a table, work with the table and when you have to save, you generate the complete CSV again.

Understand that CSV is, above all, a way of storing information, that it is universal and is easily exportable to other devices.

If you want to work with CSV anyway, I think it's simpler:
1- Read CSV and create the table when starting the screen.
2 - Make all the modifications with the table.
3- At the end (or every so often) generate the complete CSV again and save it to a file.

Thus, you can also delete rows, modify them, etc. and not have to worry about working with the CSV file to delete rows or modify elements.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.