• Dear Cerberus X User!

    As we prepare to transition the forum ownership from Mike to Phil (TripleHead GmbH), we need your explicit consent to transfer your user data in accordance with our amended Terms and Rules in order to be compliant with data protection laws.

    Important: If you accept the amended Terms and Rules, you agree to the transfer of your user data to the future forum owner!

    Please read the new Terms and Rules below, check the box to agree, and click "Accept" to continue enjoying your Cerberus X Forum experience. The deadline for consent is April 5, 2024.

    Do not accept the amended Terms and Rules if you do not wish your personal data to be transferred to the future forum owner!

    Accepting ensures:

    - Continued access to your account with a short break for the actual transfer.

    - Retention of your data under the same terms.

    Without consent:

    - You don't have further access to your forum user account.

    - Your account and personal data will be deleted after April 5, 2024.

    - Public posts remain, but usernames indicating real identity will be anonymized. If you disagree with a fictitious name you have the option to contact us so we can find a name that is acceptable to you.

    We hope to keep you in our community and see you on the forum soon!

    All the best

    Your Cerberus X Team

Not Exiting app with OnBack

Pierrou

Well-known member
Joined
Jul 6, 2017
Messages
237
Hi,
I'm doing an app for smartphones (Android at the moment, iOS when I can use someone's Mac) and usually on those platforms when using the any app's Back button, the app disappears and one gets back to the phone's "desktop" but it's not closed and one can then get back to it.
I'm using fantomCX and at the moment the only way to do something close to this is to use fE.ExitApp() but when using it the app starts over again when one goes back to it. Is there another way to use the OnBack method to go back to the desktop without closing the app so that one can resume it?
Thanks!
 
Last edited:
I'm not 100% sure but I think you need to use the general exit command which is
Error(""). Android is not supposed to exit (only resume) and neither is HTML, so that is why it is called error and you can give it a message or just leave.
 
Thanks Jimmy, using Error("") leads to the same result, my app starts over again when selected.
 
Thanks! I don't quite get why I would put it inside OnUpdate? I was wondering if there was some Function/Method somewhere I had been missing but if that's not the case nevermind.
 
Exiting the app is collected as a Crash these days with Apple and Google and will give you worse search results when it accumulates to much. So I would advice against this. Let you user close/exist the app like he/she/it is surpose to do via the operating system.

I think Jimmy reported once that the OnBack method isn't called when the app is closed. I still need to look into this.
 
So I shouldn't use fE.ExitApp at all? And shouldn't use the OnBack button to temporarily go back to desktop for now?
Thanks Mike!
 
So I shouldn't use fE.ExitApp at all?

On Mobile, not. As it causes a crash of the app. You can use the Back button, but I think it has no effect regarding the call of OnBack/OnClose on Android. Something seems to be off here, when we read other users posts on this Forum. I didn't try myself, so I have to look into this more closely.
 
OK I'll be using OnBack for in-app navigation only then, thanks!
 
Back
Top Bottom