Issue
Here is my code, I just don't fully understand how RecyclerView works.
class EditActivity1: AppCompatActivity(), FfragmentInterfes {
lateinit var mBinder : ActivityEdit1Binding
lateinit var imageAdapter:ImageAdapter
private var dialog=D()
private var chooseImageFrog:FragmentList? =null
var editImagePos= 0
public override fun onCreate(savedInstanceState: Bundle?) {
super.onCreate(savedInstanceState)
imageAdapter = ImageAdapter()
mBinder=ActivityEdit1Binding.inflate(layoutInflater)
setContentView(mBinder.root)
init()
}
Solution
just like the name, RecyclerView is a class that used for represent a list of data.
Example case, if you have profile page, you will bind user name data to some of textview. But how if you have a lot data with same pattern ? let says you you have a list of contacts data, there is have a phone number and name data.
there is RecyclerView will work for you, they will help you to bind the data to the View.
about how to connect RecyclerView. you can search with easily on google. there is lot of example
Answered By - Gandhi Wibowo
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.