What am I doing wrong?
I have the following blocks:
And Data:
Dataset.txt (6.6 KB)
You have a stringified JSON in Dataset.txt, so you need to encode this to an AI2 list using the web component JSONTextDecode block.
Then you can select individual list items as i have shown for label 2.
Also your whole data cannot be converted into list either by using listfrom csv row text or list from csv table text.
better try to save the data in this format, then we can convert it into list using the block, list from csv table text
["05/18/2022 18:37 20:00", "125", "144", "171", "03:23", "85", "98", "116"]
["05/19/2022 18:33 20:00", "133", "148", "165", "10:19", "90", "101", "112"]
...
Well it could... one could use replacement text blocks to remove the square brackets, then use list from csv row
As per usual:
Ouch! I use the app offline
i manually removed the square bracket and read from the text file , but still gives me it is not in well formatted so used split text at , and it gives me 1000
ok I did previously try removing the square brackets ... must have made a mistake
Right, I forgot that list from csv row
doesn't handle quoted items well ...
Wes, you have two options then
or 0 zero options ... cant do JSON or [ ] remove
May be this topic cooking me. Still both method gives me 1000 items and not as a table list. Each item is works as a list item and not a s table list?
json block gives first item only as csv row
the dataset is accurate. it is originally saved by working data in my app
[
["05/18/2022 18:37 20:00", "125", "144", "171", "03:23", "85", "98", "116"],
["05/19/2022 18:33 20:00", "133", "148", "165", "10:19", "90", "101", "112"]
]
this format will give you as a table list and you can parse into each item. also can read the first item from each row
Dataset is good. Each string is parsed on string commas to a DataTable
Cant do JASON because app runs offline only
What is wrong with my solution? This will work offline.
You mean this one Tim?
one could use replacement text blocks to remove the square brackets, then use list from csv row
Tired....
Bedtime here. Will try that in morning ..
Thanks Tim
No, I mean the one with the JsontextDecode block.
I am sure you are right .. however ...
I haven't been writing coding for a couple years. Still working on how to use "List from CSV Row"