Questions tagged [simpleadapter]

SimpleAdapter is a basic Android adapter which can be used to map static data to views in a xml layout.

A SimpleAdapter expects that the data supplied to be in the form of a List of Maps, where each Map represents the data for one row. The SimpleAdapter is a limited adapter by default, it will only bind data to an ImageView or TextView, for any other views the user must either use a ViewBinder or override the adapter's default behavior. More can be found in the documentation of the SimpleAdapter.

334 questions
2
votes
1 answer

Getting the _id of the rows in ListVew right

I have a ListView which shows a bunsh of values from a SQLite table. First I used a SimpleCursorAdapter to fill the ListView based on a Cursor from an SQL query. I switched over to using a SimpleAdapter in stead because I had to manipulate/add data…
2
votes
1 answer

Android - adding photos taken by the user into a listview

I currently have a simple list view adapter that holds two rows of text. What I am trying to do next is add the option of displaying a photo that the user took in the list view. I modified my list adapter like so: standardAdapter = new…
Splitusa
  • 1,161
  • 7
  • 31
  • 51
2
votes
2 answers

Change color of an item in ListView with SimpleAdapter

I'm populating a ListView using a SimpleAdapter ArrayList ciboList = null; ArrayList> data = new ArrayList>(); for(int i=0;i
Mangusto
  • 1,507
  • 1
  • 13
  • 29
2
votes
1 answer

Android Shared Prefs Map key-values to ArrayList to ListView row - UPDATED

Here's what I'm trying to do: - Retrieve a Map of key-value pairs from a SharedPreferences object (User#, Name) - write those key-value pairs into an ArrayList such that I can - use them to populate a ListView with each row containing BOTH the key…
Bennett Von Bennett
  • 297
  • 1
  • 6
  • 17
2
votes
1 answer

Android: How can you set the value of a ratingBar within a ListAdapter?

I'm trying to figure out how to set the value of a ratingBar that is in a list, but haven't been able to figure it out. I'm currently using a simple adapter to set the text. Where mylist is a hashmap. ListAdapter adapter = new SimpleAdapter(this,…
user401183
  • 2,452
  • 4
  • 25
  • 25
2
votes
1 answer

Retrieving Original HashMap from a SimpleAdapter/ListView on Item Press

I have a SimpleAdapter that populates a ListView, but when the user presses an item I'd like to be able to get the original HashMap that was used to populate the row that was clicked. Unfortunately it seems that all I can get back is an Object which…
Nick Betcher
  • 1,871
  • 4
  • 18
  • 25
2
votes
2 answers

Creating Multi-Column Layout with ArrayAdapter

I've been trying to fix this problem for a while and have exhausted all the different Google searches that I could think of. I'm a beginner with Android, but understand most of the fundamentals (I think). Anyways, I'm trying to display a list of…
trevor-e
  • 9,857
  • 8
  • 47
  • 73
2
votes
1 answer

How to Display images in a simpleAdapter form URLs (XML feed)?

Can anyone please help me to Display images in a simpleAdapter form URLs. I have these URLs in my XML file. in my simpleAdapter I have "R.drawable.imageView1" I can display text but can't get the image. I have a method to get the URL from the XML…
user840801
2
votes
3 answers

SimpleAdapter not showing data on GUI

This is the first android app I'm writing for the college I work at. It's basically a thin client that reads data from an xml on the site and prints it out to a List. I've ran into a strange problem though and could use some help. The…
Tyler Ferraro
  • 3,548
  • 1
  • 21
  • 27
2
votes
2 answers

how to get bitmap image from hashtable into simple adapter to view in imageview for listactivity

Below is my code. I am getting url for an image through JSONArray. Then i converted the image to Bitmap image and stored in Hashtable. I am using ImageView to show the images in listview. So i am using simple adapter for getting images. But image…
Santhosh_pulliman
  • 2,059
  • 6
  • 30
  • 46
2
votes
1 answer

want to show image after getting from web using SimpleAdapter

I am reading data from web xml file and image also from web. I get the image as Bitmap bmImg and I have putted it in Hashmap. But I do know how to modify my simpleAdapter function to show that image in the imageView. I am stuck up here and I am…
Naveed Qamar
  • 127
  • 1
  • 13
2
votes
1 answer

ListView / SimpleAdapter doesn't refresh - Android

I want to add to a ListView with the click of a button, but the ListView doesn't refresh. The HashMap itself refreshes, but the ListView doesn't. Here's my code: final ListView grupidView = (ListView) findViewById(R.id.grupiList); final…
dannyk
  • 31
  • 2
2
votes
1 answer

update listview from simpleAdapter with new data

I've implemented a custom listview with multiple TextViews from a tutorial found here and all is working very well, but I'd like to be able to update the textviews on the fly with new data. For example, I set a click listener on the items in the…
dell116
  • 5,524
  • 9
  • 48
  • 68
2
votes
1 answer

Calling view by id in customized SimpleAdapter?

I want to add some customized operations when use a SimpleAdapter for a ListView. So I write a MySimpleAdapter to extend SimpleAdapter. I need to hide an ImageView if the image url is null. However, when view recycling works, those views with…
mrmoment
  • 699
  • 1
  • 8
  • 32
2
votes
1 answer

Android - How can diplay pictures in a simpleApapter list view

I'm trying to display te pictures in a SimpleAdapter listview. I included Picasso in my project but i don't know how to use Picasso with a SimpleAdapter. List> featured = new ArrayList>(); …
1 2
3
22 23