Wait for 5 seconds

See if this works for you. Be sure to import the android.os.Handler

      Handler handler = new Handler();
            handler.postDelayed(new Runnable() {
                public void run() {
                    // yourMethod();
                }
            }, 5000);   //5 seconds

or Kotlin

Handler().postDelayed({
    // yourMethod()
}, 5000)

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)