‘this@ActivityName’ is not captured error Android/Kotlin

fyi lambda expression like setOnClickListener from kotlin is not debuggable, see here.

if you want to debug variables inside setOnClickListener you should use the normal one e.g. setOnClickListener(object: View.OnClickListener {..})

Leave a Comment