After updating to 183, the Back button does not work properly

Everything worked fine before the upgrade. After pressing Back, it only executed the commands from "when.screen1.backpressed". Now it performs these commands and closes the application immediately.
I suspect this patch has broken something:

Use onBackPressed instead of onKeyDown (thanks @bartmathijssen)

Although I do not know what was corrected here since the button worked well ...

About me, it do not close the application only, but also go back to the last screen.

For me, first executes the commands that are placed in “when.screen1.backpressed”, then closes the application. In commands placed in “when.screen1.backpressed” I do not have a command closing the application. Now the back button closes the application by default, regardless of what is in “when.screen1.backpressed”.

1 Like

Good afternoon.
When using this BackPressed block,
the assistant closes and reconnects.
All screens are registered
blocks

Release nb183 broke how BackPressed functions. MIT will provide a patch when they can.

I merged your topic. Your question was already asked. There is already a fix available.

(added to FAQ Section: App Inventor Issues)

Help, I’m working on an app for a school contest and after 3 months this bug is going to mess up all my project. We have to send it tomorrow. Is there any way to fix this problem with the code you posted or we must wait for a patch?

good morning, any forecast for the correction to rise?

If I am understanding correctly, this is only affecting compiled apps. Is that correct?

that’s right, in my case I compiled today and it happened.
when you press to go back it always closes the window (back to the previous one), without you having added the close screen command

No, happens in companion as well (for me)

Please try rebuilding your app on this server and see if it works.

2 Likes

this server

here works normally

Intenta con el comando de cerrar la pantalla con un valor absoluto,para quitar el error que se que devuleve a la ultima pantalla

Same problem here, and I can’t log into your supplied server link…

Blockquote
Oscar_Reis
this server
here works normally

the link does not access the server ... how to do it?

hi how do I apply the fix?

You will need to wait until the fix is applied to the main AI2 application, or temporarily use the build as provided in the link above