Issue
Unable to run OnSetClickLestiner
Solution
as I can see you cant find the button with the id. You have to options
1st option: go to ur code and use the line
val myButton: Button = findViewById(R.id.button)
myButton.setOnClickListener{
...
}
2nd option: go to gradle.app file and add into the plugins the line:
id 'kotlin-android-extensions'
and then keep the same code as you have
Answered By - NickNterm
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.