Search
 
SCRIPT & CODE EXAMPLE
 

JAVA

stop countdown timer when exiting an activity

@Override
public void onFinish() {
    val = 0;                                                                            // When time finish go for mainActivity
    Intent intent = new Intent( second_five_questions_questions_1.this, second_five_questions_questions_2.class);
    intent.putExtra("key", val);
    intent.addCategory(Intent.CATEGORY_HOME);
    intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
    startActivity(intent);
    cancel(); // add this to cancel out countdown
    finish();
}
Comment

PREVIOUS NEXT
Code Example
Java :: how to make a ordering system in microsoft visual basic 2010 express console application 
Java :: java arduino 
Java :: online currency rate api 
Java :: like clause with param in spring jpa 
Java :: JAVA Display numbers from 1 to 5 
Java :: java windowbuilder full screen 
Java :: records java final 
Java :: how to get the current location in android 
Java :: convertBirthDay java 
Java :: exception handling and reprompting 
Java :: Mirror Inverse Program in java 
Java :: menuitemcompat getactionview is deprecated in android 
Java :: comparable interface 
Java :: load local json 
Java :: kotlin dependency injection 
Java :: hide frame ( acces to the top level component ) 
Java :: how to put array in array list stack overflow 
Java :: missingWords 
Java :: torres de hanoi java 
Java :: run jar with logback config file 
Java :: 111111000 
Java :: fibonacci java 
Java :: Java Get float, double and String Input 
Java :: system program j 
Java :: Java Super Power java 
Java :: replace range from array java 
Java :: bukkit scheduler self cancelling task 
Java :: java define interface 
Java :: okhttp3, android okhttp 
Java :: java tutorialspoint 
ADD CONTENT
Topic
Content
Source link
Name
3+3 =