2014년 12월 15일 월요일

Strange situation and Urgent

I'm facing something strange here. I ask the app to download questions from a db and store them in a tinydb. then convert them to a table from csv and name it questions. All good until question 7, When I check the converted list, it shows question 7 in two parts : (7 bla bla bla argentina.)(My blabla140) does the same with 8-9-10-11-12-13-14. 

But when I check the stored data from tinydb, it shows the data as it shows the rest of them. I'm uploading the two differences. The code is the same, the data is the same, but just between those 7th and 14th questions, strangely it cuts the data in two. And I checked, there are no commas or double quotes. I've been on this for two hours now and I can't find a solution. 

You can see the photos of text versions: CSVTABLE shows question 7 in two parts seperated with brackets (7....)(....) but 6th one as (6....) in one bracket.
DBDATA shows all the same: 6..... next line: 7.... next line: 8....





This separation of data might be a timing error and a result of how you download from a database (you do not say what type) and then store on the TinyDB.    You do not also say how large the database is; that could affect how the List is populated.    In App Inventor, activities are event driven; AI2 can not simultaneously process two threads.  What this means is that if you attempt to start a second activity before a prior activity finishes, there could be issues.   Is this your problem?    No idea without more information about your database, how you download to the device, convert to a list then store in the TinyDB.

Post some blocks and answer the questions and possibly someone can provide specific advice.



It would really help if you provided a screenshot of your relevant blocksincluding Do it result of the csv table and the original data, so we can see what you are trying to do, and where the problem may be.



My Bad! ..

sorry everyone, after thoroughly checking ever item in the database, I found out that I hit the enter key after those questions (7-14). sorry for the trouble.


댓글 없음:

댓글 쓰기