Angular / get the current activity


#1

How can I get the current Activity on android , and kill the current activity


#2

@Fabiyo NativeScript works on single activity and fragments. You must be able to gain access to the that activity using application.android.foregroundActivity.


#3

I wanna use this function for killing the current activity

https://developer.android.com/reference/android/app/Activity.html#finish()


#4

You should be able to call finish on the foregroundActivity.
application.android.foregroundActivity.finish()