Android Question Monitoring the execution time of another app

Giovanni Raco

New Member
Licensed User
Longtime User
I tryed a programming an app for monitoring the execution time of another app. I search into forum but not found a correct way. I write this code

Dim lstname,lstpid, lstnamepid, lstret As List
lstname.Initialize
lstpid.Initialize
lstnamepid.Initialize
lstret=OS.RunningAppProcessInfo(lstname,lstpid,lstnamepid)
Dim i As Int
For i = 0 To lstname.Size - 1
If lstname.Get(i) = "com.twitter.android" Then
Counter=Counter+1
.....
The problem is, when the twitter application is in Pause state of activity, the RunningAppProcessInfo found the process. Exist a way for monitoring or intercept the Activity main state for the app of monitoring ??
 
Top