Skip to content

Instantly share code, notes, and snippets.

@vinodbaste
Last active September 28, 2023 06:39
Show Gist options
  • Save vinodbaste/af51e3b0d522b1ef11ad947dce74de17 to your computer and use it in GitHub Desktop.
Save vinodbaste/af51e3b0d522b1ef11ad947dce74de17 to your computer and use it in GitHub Desktop.
class SplashScreenActivity : AppCompatActivity() {
override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
setContentView(R.layout.activity_splash_screen)
Handler().postDelayed(Runnable { //This method will be executed once the timer is over
// Start your app main activity
val i = Intent(this@SplashScreenActivity, MainActivity::class.java)
startActivity(i)
// close this activity
finish()
}, 3000)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment