Reputation: 107
I wrote a code like that:
var btn: Button = view.findViewById(R.id.btn)
view.findViewById(R.id.btn) is red underlined. It's working fine but Android studio tolds me that it is mismatch type (Compiler expected View!). It had been working fine until i changed a profile from debug to release. Since that it show me errors.
And one more error which i recived is with:
view.findViewById<TextView>(R.id.user_name)
TextView is red underlined. No type args expected for fun.
I belive that error s only becouse of android studio config. I can compile my code witout any problem, but android studio doesn't suggest me things like that.
Have you maybe any suggests ?
Upvotes: 0
Views: 31
Reputation: 51
Have you tried to rebuild and clean your code? @Young_User
Might be an issue with what you are inheriting in your class.
Care to share the error code and full class too?
Upvotes: 1