The compiler gives me an error
Error: (97, 17) Val cannot be reassigned
but the variable is declared as var .
Edit: You can see the comments in my code. When I assign rcv = recyclerView and
chkStrictSearch = checkBox I get a red underline here with a tooltip with an error message
Below is my code:
private var rcv: RecyclerView? = null private var chkStrictSearch: android.widget.CheckBox? = null private fun getMainView(): View{ return with(context){ frameLayout{ lparams(width = matchParent, height = matchParent)
Rahul source share