Blank screen after switching screens

Since the project works fine on android and shows weird errors on iPhone, maybe @ewpatton would like to take a look at it. Screen3 exists in your app so there shouldn't be a problem with it.
But instead of horizontal and vertical layouts, it contains a table that I don't trust and that has had problems in the past... and I'm wondering if it's not a table problem.

I understand but I personally do not think it is a table problem. This error happens with all screens if I keep switching for long enough:


If I had to guess, I would say that there is something wrong happening with the BMI formula calculation. In my opinion this is somehow messing up with the project. A friend of mine did a similar project but with the formula result showing up in the same screen in which you input your data and it worked propperly (he is also using IOS).

Try it

CALCULADOR_IMC_1.aia (74.9 KB)

Your images should also be sized to match the size of the buttons.

Leo, in Screen3 you are using a Table Arrangement, for which unfortunately there are occasions when file corruption is caused.

Delete Screen3, create a new Screen3, arrange the GUI again using Horizontal and Vertical Arrangements.

See my edit below for Screen1 and 2. Screen3 should be called and closed in the same way Screen2 is.

Note the safety check - are there values in INSERIR_ALTURA and INSERIR_PESO.

Note also that to use Textboxes for numbers, the Properties palette option "Numbers Only" should be ticked.

Finally, button USUARIO could not be seen on my phone, it was off screen, so I reduced the height of it's Arrangement and made the screen scrollable.

CALCULADOR_IMC_Edit2.aia (73.9 KB)

Thank you for your feedback. I tried using your file and it worked once, but then it suddenly stopped working. Also, if the values for height(=altura) and weight (=peso) are empty, Screen2 loads propperly. That is wwhy I think the formula is messing up the loading of the screen.

That is another App-Killer issue Leo. Your images are far too large. Read this:
ProfessorCad: Tips & Tricks Images

Hmm - this post is similar to:

Thank you for your feedback. This is the updated version of the project:
CALCULADOR_IMC (2).aia (74.8 KB)
I understand that the design/coding of Screen3 is far from optimal but it is loading propperly now. My only issue is when I insert the values and try to load Screen2. As I mentioned, only a blank screen shows up.
Also, I noticed that I should tick the only numbers box but, by doing so, I can only insert numbers with "," and not "." which also causes troubleshooting (the BMI formula won't work then).

The blank screen problem arises because on the first screen you open screen2 and close screen1. You only have screen2 open. On screen two, you close screen1, but you don't open any screens, so you have no screens. Try the aia from Chris because he corrected it there.

I tried his version but still no luck. I get what you are saying, but the ideia is to click on the arrow to reopen Screen1, so I do not know if this would be an issue at all.

Try it:
CALCULADOR_IMC_1 (1).aia (75.1 KB)

If that doesn't work, we'll try not to close screen1

And write if you have a problem with manually switching screens in this version.

Still no luck. Also going back from Screen3 to Screen1 by clicking the "arrow" button is now causing the app to crash somehow (only in the project you sent me though).
Also tried not closing Screen1, and it keeps showing a blank screen.

Last try. I don't have an iPhone so I can't help much.
CALCULADOR_IMC_1_copy.aia (74.7 KB)

What else comes to mind is remove the image component and don't display the image on the screens.

It still won't work. Thanks a lot for the effort and time spent trying to help me though and sorry to waste your time with this.

Also try removing the image component from your screens.

Yes, because with Companion there is only one screen, so you can't close Screen2 or Screen3 without opening Screen1 again. This also does not work with Android.

I'll take a closer look at your app tomorrow.

1 Like

Projects are inserted above that do not close screen 1. They also do not work according to the author of the post.
I have an android project with only 1 screen open. There is also a project that has 2 screens open at the same time.

But not with Companion.

I have no problem with that.
2 screens:
CALCULADOR_IMC_2_copy.aia (74.7 KB)
1 screen:
CALCULADOR_IMC_1_copy.aia (75.0 KB)

They both work the same for me on companion. None of them work for the author of the topic.

1 Like