Hi,
I am using a timer in one of many activity's in my project.
I have declared this timer in Process Globals and Initializing it in the Activity_Create sub like below:
Sub Process_Globals
Dim MyTimer As Timer
End Sub
Sub Activity_Create(FirstTime As Boolean)
If MyTimer .IsInitialized = False Then
MyTimer .Initialize("MyTimer ",10)
End If
MyTimer .Enabled = True
End Sub
Sub MyTimer _Tick
' This code will trigger every 10 ms
End Sub
I have read a thread where Erel said:
Timers should be declared as process globals. Otherwise new timers will be created when the activity is recreated.
It is recommended to pause the timers and resume then in Activity_Pause and Activity_Resume.
The question I have is what if I don't pause the timer when moving to another Activity or even when I press the home button and the app is running in the background?
Will that mean my app/Activity will come up with a error next time it loads or even cause the app to run out of memory ?