How to pass the values from activity to another activity in kotlin

前端 未结 7 885
北恋
北恋 2020-12-03 10:13

As I\'m learning Kotlin for Android development, I\'m now trying the basic programs like hello world and how to navigate from one activity to another activity , there is no

7条回答
  •  无人及你
    2020-12-03 11:12

    I'm on mobile, you must test by yourself.

    Try to make a CharSequence to a String in MainActivity , you have put a CharSequence rather than a String, for example:

    var userName = username.text.toString()
    var password = password_field.text.toString()
    

提交回复
热议问题