Hello! I am new to Android and I can’t figure out how to use cardview and recyclerview . help me please. was on different sites, but still does not reach me. I have this cardview code here.

  <LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="vertical" android:background="#172131"> <ImageView android:id="@+id/imageView2" android:layout_width="match_parent" android:layout_height="150dp" android:scaleType="centerCrop" app:srcCompat="@drawable/rest1" /> <TextView android:id="@+id/info_text" android:layout_width="match_parent" android:layout_height="match_parent" android:layout_marginTop="-47dp" android:background="#64212C3E" android:padding="10dp" android:paddingLeft="10dp" android:paddingTop="10dp" android:text="Название" android:textColor="#dcffffff" android:textSize="20sp" /> <TextView android:id="@+id/info_text2" android:layout_width="match_parent" android:layout_height="match_parent" android:layout_marginBottom="5dp" android:padding="10dp" android:paddingBottom="10dp" android:paddingLeft="10dp" android:paddingTop="10dp" android:text="Описание бла бла бла бла бла бла" android:textColor="@android:color/white" /> </LinearLayout> </android.support.v7.widget.CardView> 

Please explain how to link this cardview with recyclerview.

Closed due to the fact that the essence of the issue is incomprehensible by the participants of Suvitruf , cheops , post_zeew , ߊߚߤߘ , αλεχολυτ Nov 28 Nov '17 at 8:57 .

Try to write more detailed questions. To get an answer, explain what exactly you see the problem, how to reproduce it, what you want to get as a result, etc. Give an example that clearly demonstrates the problem. If the question can be reformulated according to the rules set out in the certificate , edit it .

  • 2
    Describe in more detail what exactly is not clear to you. Otherwise, how to help you besides giving links to articles that you did not understand? - YurySPb
  • In the articles that I read, they show how to add a cardview, but they don’t explain what to do with it, or they give you the finished code, but I also don’t understand anything there - Alex Stuart
  • one
    It is not very clear what you expect from us, what kind of help. We can write an analogue of articles that you do not understand - but why? Hundreds of them have already been written and they are not clear to you. In addition, such articles are not entirely in the format of the site. Now, if you cited some specific example of code that you do not understand - then another thing - at least it will be clear what to answer. - Yuriy SPb
  • one
    Probably, the difficulty lies in understanding the work of the adapter and connecting the libraries that are involved in the lessons. - nuqss
  • I did everything like here developer.android.com/training/material/lists-cards.html?hl=en wrote the cardview code and recycler view, and now I want to understand how to connect them. I also want to understand how to make new cards appear - Alex Stuart

0