File problem with saving

I don’t know why when i save a file in one project it saves with parenthesis and in the other with claudators, pls help

It would really help if you provided a screenshot of your relevant blocks, so we can see what you are trying to do, and where the problem may be.

To get an image of your blocks, right click in the Blocks Editor and select “Download Blocks as Image”. You might want to use an image editor to crop etc. if required. Then post it here in the community.

Taifun


Trying to push the limits! Snippets, Tutorials and Extensions from Pura Vida Apps by Taifun.

You are trying to save a table (list of lists) to a file.
You must first convert it to a csv table format using the csv table conversion block,
which will make it into text in a way that can be reversed when you read the file later.

If you’re saving a list and it’s saving with parentheses, then on Screen1 you should see that ShowListsAsJson in the designer is unchecked. In the one with square brackets and quotation marks, that property will be checked. Just check (or uncheck) the option as desired.

that was the problem, thank you so much you save my live

2 posts were split to a new topic: How do you make it so that when you hit a button it saves a apk file

Hi,
I would like to solve I similar problem.
I' m trying to save/retrieve a list of lists , contained in a tinyDB tag, with Save/Read File blocks and nor block " list to csv table" works for me nor checking "ShowListsAsJson" as ewpatton suggested in this topic (marked as solution for the guy which started it).
As you can see , my file was only partly converted (with or without the above mentioned checking, th only difference is the kind of pharenthesys "()" or "[]")
(see result saved file enclosed - the .txt suffix was not present and was added to comply with this forum rules)

2020_7.txt (115 Bytes) 2020_7.txt (143 Bytes)

The inner lists are left untouched and when retrieved from saved file and converted with block "list from csv table" they are not recovered as lists anymore.
Here the blocks involved and the original content of tinyDB tag






The strange thing is that the content of new tinydb tag is equal to the old one but an error shows when that list is loaded by the loop who manage it.
I cannot identify the problem.
Please, can you help me?
Thanks!

as the error message is trying to tell us, it seems to be you have an issue with a length of list block... the queston is which one?
you are already familiar with Do it, which is great!
you might be able to find out, when exactly the issue occurs? just try a Do it on the corresponding length of list block which might reveal the issue...

Taifun


Trying to push the limits! Snippets, Tutorials and Extensions from Pura Vida Apps by Taifun.

The problem is in the csv table conversion; the block accepts and manage without errors a list like this one:
blocks6
but with this other one the errors appear:
blocks7
if you look at this aia you can see the behaviour
prova.aia (220.2 KB)
I must find a solution to package the lists in some way to save them as a string, recoverable later

See here:

Its already a string:

I do not understand the point, sorry, the list is readable before the conversion and is no more after; to me, it must be correct no matter what the list structure is.
So I found a solution encoding the list as json object and then decoding it with web component.
Now it works perfectly (or, at least, it seems so...;-)) )
Thank you everybody for joining in the discussion and helping , bye

What is so difficult to understand about this: it is not a list.

Please, why don't you take a look at the whole subject?
The string is just the erroneous result I do not want or need; however, if you have a more elegant solution than that one I have envisioned, please, let me know, I would implement it for sure.

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