Attempt to get length of null array error message

Yes sure, here it is :
TrekoRando-fr-Translation.zip (238 Bytes)

I have made it manually :innocent:

Some methods of TaifunFile does not work in Companion.

I found the problem, you need to delete it (what is marked in yellow)


-Leave only: TrekoRando

1 Like

This is what I said @Point :slight_smile:

For some reason I did not notice it :thinking:

1 Like

Oops, i’m sorry, actually I changed this part to make some more simple tests (not constructing the filename), and forgot to changed it before posting the image.
The good image is here :

But unfortunatelly, it still leads to the same error message :pensive:

I noticed you sent here a ZIP file containing the json file Did you add the ZIP file to the assets?

no of course, it is directly the .json file in the assets (zip was created to be allowed to upload it :wink:)

I don’t think you are interested in reading my posts.
Read it at least once and if it works then let me know.

Sorry, of course i’m interested in every answer that could help me to resolve my issue.
But i’m freshly new and really don’t know what to do… Maybe you can tell me what can I do instead of telling me it’s not working :wink:
I’m still wondering how all of this works !!

Do you mean that the only way to make it working is to generate the apk and install it on my device to test ? :face_with_raised_eyebrow:

Short Answer: Yes
Alternate Answer: Use this file manager extension-


Why
TaifunFile extension was originally made for App Inventor and its distros who use the same path for asset storage but a few months ago Kodular started using a different path and thus the extension does not work completely in Kodular Companion.
But FileTools is made for Kodular and supports App Inventor also.

2 Likes

Thanks a lot for your advice !
I tried your extension, only by replacing the .FileListFromAssets block as shown here

Now I have no error message but on my app, in label1 and label2, i have this message :

:exploding_head:

Now you have to work on the suggestions given by @dora_paz and @Point.

1 Like

Ok I tried to do the same thing as How to effectively translate your application
and I have the messages : “There was a problem to get the string ‘String1’. Make sure on your side is all correct.”
Same message for String2 and of course I have re-uploaded the json files with same values than in tutorial

I used FileTools extension…
:weary::gun:
:pray:

Since I have never used resource utilities so I can’t help you much in your issue but one thing is clear that asset list problem has solved as you are getting file list without any problem.
Let’s wait for other’s answers who know about or have worked with the component.

Ok thanks for all, very nice from you to help me :wink:
Actually i’m just searching for a way to translate my app easily before whole coding it !
I would prefer to use CSV file instead of json because it is more user friendly to update, but only found the solution with json files :confused:

No that’s not completely true.
You can make similar thing using lists.
But it requires a lot of time and logic.

  1. Edit json file , replace label1 with string1 and label2 with string2.

  1. Change the Translate procedure as shown below

image

Try this aia and tell me if it works

translation_app.aia (64.0 KB)

2 Likes

Hello all,
sorry for delayed answer (i was limited in number of posts due to my new accout).
At last, I succeed to make my blocks work correctly, the solution is effectively provided in How to effectively translate your application but in a Block that don’t directly displays the image :no_mouth:
So until I found it, my blocks were based on the first image of the post :woozy_face:

Now it’s ok, thanks for all !

1 Like