Problem with TwoActivities demo using CallSubDelayed

GlenAlan

Member
Licensed User
Longtime User
The TwoActivities demo using CallSubDelayed works perfectly when I select an Item# number in Activity2 and it returns and displays it in Activity1.

However, when I now press the [Back] button in Activity1 (to exit the App), it returns to Activity2. When I then press the [Back] button in Activity2, it exits the App.

How do I get the App to exit when pressing the [Back] button in Activity1?
 

barx

Well-Known Member
Licensed User
Longtime User
I haven't seen the code of this example, but try this.

After the CallSubDelayed call in activity2 add the following line.

B4X:
Activity.Finish
 
Upvote 0
Top