How to pause an android app -
I want to create an application that displays some information on the screen, waits for a while and then some more Does the Android app have a simple order to stop? I'm using Android 4.2.2.
You can use the handler class:
Make an example: < / P>
handler HK = new handler ();
Use your example to run a post () method:
Last Boolean Post Delayed (Runable R, Long William Millie)
Runable R to be added to the message queue can be added to run after the specified time.
The Post Delayed () method requires feeding with runnab, which contains the code that you must have after delay milliseconds.
Runner class can be done as follows:
class runner runnabel {public zero run (// // your code}}
as a simple example:
handler handler = new handler (); Handler. Post Delayed (New Runner (2000));
Comments
Post a Comment