Answer by Siddharth Utgikar for Show ProgressDialog and call OnBackPressed()...
onBackPressed() should be called from the UI Thread. What Darshan has suggested is the correct answer. When you want to update UI from a background thread (in this case the thread that waits for your...
View ArticleAnswer by darshan for Show ProgressDialog and call OnBackPressed() after...
Try using a Handler().postDelayed() like below - new Handler().postDelayed(new Runnable() { @Override public void run() { //hide progressbar onBackPressed(); } }, 5000);
View ArticleShow ProgressDialog and call OnBackPressed() after certain period
The ProgressDialog should display for 5 secs after which OnBackPressed() should execute. Currently the ProgressDialog never appears on screen. If I put OnBackPressed() inside the delegate progress...
View Article
More Pages to Explore .....