0

I have 100 items, all have an image and some description, i have a ListView and i want to open the items with ListView, so how do i do that ? i want to show description and image for each item. do i need 101 activities?

Spring Breaker
  • 8,233
  • 3
  • 36
  • 60
Apk
  • 153
  • 1
  • 2
  • 18

3 Answers3

0

No You Can Use Listview With Image And Text Using List Adpter Here I Send You Link See My Answer Step By Step U Follw it.Listview With Imageview

Community
  • 1
  • 1
ishu
  • 1,322
  • 1
  • 11
  • 15
-1

Fedor's LazyList is simple and very efficient, and loads the images from a URL, but I could also modify it to load images from resources folder.

Community
  • 1
  • 1
Sushil
  • 8,250
  • 3
  • 39
  • 71
  • that is also possible with this code. I did it offline only. Little alteration is needed. The code is very efficient. Since you load 100 images, so u need to take care of memory. With this it is possible – Sushil Jan 29 '14 at 06:38
  • http://theopentutorials.com/tutorials/android/listview/android-custom-listview-with-image-and-text-using-arrayadapter/ – Apk Jan 29 '14 at 06:48
  • but i see three packages in the example, can i put the three class files in one package instead? – Apk Jan 29 '14 at 06:49
  • ya u can put this three class in one package and ya u have to compulsury take three clas – ishu Jan 29 '14 at 06:57
-2

No, you only need one activity and one Fragment. Each time you click one item in the ListView, call replace and update your fragment. I think that should be method that helps you refresh its content view . Or you can create a new one (not best solution)

suitianshi
  • 3,300
  • 1
  • 17
  • 34
  • need one adapter class and main activity then add adpter to listview . for more information check this link :- http://www.androidhive.info/2012/02/android-custom-listview-with-image-and-text/ – Dakshesh Khatri Jan 29 '14 at 06:22
  • @user2968888 what do you mean? you really understand the question? – suitianshi Jan 29 '14 at 06:25