Screen-Open-Problem

Hello,

Since some hours, I try to make a subscreen opened, but it always fails. I only see after the button click on the Screen one on the subscreen navigation a black screen and the information, that I can wait or close the app. I also copied this screen and created a new screen with a new screen name. But it still fails. The base of this app was my Sütterlin app from where I copied all content and then I changed different content. I did not want to program the features from the scratch. I tried all, I know, what could help, but now I am at the end of my knowledge. Could someone please help? I also add the AIA and two screenshots from my files, the one image is Screen1 and the other the screen with the opening problem. By the way, the app also does not open in the Emulator and writes a runtime error or something like this. Thanks!




FrakturschriftTrainer.aia (6,8 MB)

Has you read this What is the Max number of screens that can be used in a app to be able to still publish the app ?

here is the result from https://unchive.kodular.io

number of screen is 8, this is fine

what you should do especially in screen SuettelinQuiz is to follow the DRY principle of programming... don't repeat yourself

Here is a quiz example for you:

Taifun

  • Reduce your block count:
    • Use parametrized procedures for common code
    • Use Media text files instead of big clumps of text blocks
    • Use generic blocks instead of repeating component event blocks
    • Encode repeating decision patterns into lookup tables loaded from Media csv text files (does your blocks image look like a box of combs?)
    • You don't need a component for every data instance. Reuse those components.
    • If you can't fit data into a ListView or List Picker, show a small subset of the data in an Arrangement and slide it across the larger list of data.

Hello Simon, the maximum of the screens is 10 screens per app, I have only 8 screens and in the present it never was a problem. Thanks. This does not solve the problem. Have a great day! Kind regards, Martina

Hello Taifun, Thanks. I did not use the "Any Button" solution, because I have more buttons for other purposes (close app button a.s.o.). The problem seems to be that something has crashed during copying the app from the original Sütterlin app and I cannot find the error. Thanks!

See here:

especially here: Error from Companion: Font asset not found /storage/emulated/0/Android/data/edu.mit.appinventor.aicompanion3/files/assets/default - #6 by Patryk_F

and do NOT open screens multiple times!

What is the purpose of that Screen?

All it does is present the words of a sentence, and give the opportunity to select a word and display it in a Label. No judgement is made as to whether that word is right or wrong.This could be done with a tiny piece of code, and sentences loaded from a Media text file.

The isNotAlreadyHandled generic event parameter tells you if there are no other button events for that component. That would test false for a close app button.