I tried this way. But I was unable to delete the tag of the CloudDB.
Can anyone see that there is any problem with my code?
The equal block is a Math operation in your block. You should use logical equal operation (the green one)
I tried that way but it didn’t worked.
I found the Taifun Image in which he used the Math Block. Let me show you.
That’s app inventor…
Ok, I will try in the way said and let you know the result.
For me also the Math block works.
So check this:
Btw, no need for an extension:
That’s weird, I thought Math operations can only work with numbers.
from the documentation Logic - Kodular Docs
It acts exactly the same as the = block found in Math
Taifun
Pause and Stop works in the same way for me.
see here about the difference between pause and stop
https://developer.android.com/reference/android/app/Activity.html#ActivityLifecycle
Taifun
Yes, because after ScreenOnAppPaused
is triggered, Screen.OnAppStopped
is also always triggered.
https://docs.kodular.io/components/screen/#on-app-stop
As I have shown in my last post (video), these statements are not correct:
(though it does not always mean the activity is being destroyed)
Yes, but at the end there is no way to come back from Screen.OnPause
to Screen.OnResume
.
So if Screen.OnPause
is triggered, in any case Screen.OnStop
is triggered as well.
did you test what happens, if the device goes into sleep?
Taifun
taken from here 2.2: Activity lifecycle and state · GitBook
The paused state can occur in several situations:
- The
Activity
is going into the background, but has not yet been fully stopped. This is the first indication that the user is leaving yourActivity
.- The
Activity
is only partially visible on the screen, because a dialog or other transparentActivity
is overlaid on top of it.- In multi-window or split screen mode (API 24), the
Activity
is displayed on the screen, but some otherActivity
has the user focus.
Your
Activity
can move from the paused state into the resumed state (if the user returns to theActivity
) or to the stopped state (if the user leaves theActivity
altogether).
Taifun
I had read that and went through all sorts of scenarios and variations.
A nice theory, but it doesn’t change the fact that OnAppPause always also triggers OnAppStop.
did you test the situations below?
Taifun
- The
Activity
is only partially visible on the screen, because a dialog or other transparentActivity
is overlaid on top of it.- In multi-window or split screen mode (API 24), the
Activity
is displayed on the screen, but some otherActivity
has the user focus.
this looks like the list of recent opened apps?
The
Activity
is only partially visible on the screen, because a dialog or other transparentActivity
is overlaid on top of it.
Probably the alarm app is an example? What happens, if an alarm rings while your app is open? In case this is not a suitable example, probably someone else has an idea how to test this?
In multi-window or split screen mode (API 24), the
Activity
is displayed on the screen, but some otherActivity
has the user focus.
see here about split screens https://www.google.com/search?q=android+split+screen, for example
Taifun