CPU use after app closure

BowTieNeck

Member
Licensed User
Longtime User
I've noticed that after I close my app Task Manager shows that it is still using the CPU.
My most recent app uses the AdMob and Reflection libraries and appears to be using up to about 8% of CPU after being closed.
An earlier app which doesn't use any additional libraries seems to be using less than 1% CPU after being closed.
In both cases I would have expected CPU use to be zero. I appreciate that the RAM would still be occupied until the operating system needs to use it but I don't understand the CPU percentage.
Should I be doing something when the user quits the app in order to stop this?
Thanks.
 

BowTieNeck

Member
Licensed User
Longtime User
Yes I do have a timer, which would still be running. I'll try stopping it when I exit and see if that improves things.
Thanks for your incredibly prompt reply.
 
Upvote 0

BowTieNeck

Member
Licensed User
Longtime User
Activity_Pause does have Timer1.Enabled = False (with no check on the state of UserClosed).

I'm closing the app like this:

Sub Activity_KeyPress(KeyCode As Int) As Boolean
Dim Answ As Int
Dim Txt As String
If KeyCode = KeyCodes.KEYCODE_BACK Then
Txt = "Exit Mondrian?"
Answ = Msgbox2(Txt,"","Yes","","No",Null)
If Answ = DialogResponse.POSITIVE Then
Timer1.Enabled = False
Return False
Else
Return True
End If
End If
End Sub

I've just added the line Timer1.Enabled = False and that seems to have fixed the problem.
 
Upvote 0
Top