Answers for "how to add fragment to second activity in kotlin"

0

how to move from fragment to activity in kotlin

btn.setOnClickListener {
            activity.let {
                val intent = Intent(it, GuardianProfile::class.java)
                startActivity(intent)
            }
        }
Posted by: Guest on May-24-2021
-2

how to start activity from fragment in kotlin

activity?.let{
    val intent = Intent (it, Main::class.java)
    it.startActivity(intent)
}
Posted by: Guest on February-15-2021

Code answers related to "how to add fragment to second activity in kotlin"

Browse Popular Code Answers by Language