Questions tagged [custom-adapter]

A custom-adapter is an interface which provides the ability to define non-standard iterators for specific data representations.

A custom-adapter is often used to integrate custom data structures with a view in an MVC framework.

References

990 questions
1
vote
2 answers

"Variable is accessed from within inner class, needs to be declared final" error in custom adapter

I'm attempting to implement a multiple choice ListView with checkboxes, and I've defined a custom adapter class, and it's as follows: package com.ameer.easycooking; import android.content.Context; import android.view.LayoutInflater; import…
user3501779
  • 157
  • 1
  • 10
1
vote
2 answers

WSO2 CEP - Custom Receiver Adapter: Event Formats

I am trying to build a custom receiver adaptor. Which will read from CSV file and push events to a stream. As far a I understand, we have to follow any of the WSO2 standard format(TEXT, XML or JSON) to push data to a stream. Problem is, CSV files…
Obaid
  • 237
  • 2
  • 14
1
vote
1 answer

CustomAdapter is not displaying ArrayList Item: ImageView

In my CheckOutMemo.class I can set any title and content as shown in picture. MainActivity.class then retrieves this title and content without any problems and displays a custom row. Like in this picture: Title = Header Content = bodyText But the…
1
vote
0 answers

In SwipeMenuListView custom row layout Textview is visible only first position when SwipeMenu is open

When i swipe SwipeMenuListview item it shows only first position's textview but i want when i swipe list item it shows all position textview's text. For Example, in my case i want 4 textview visible when i swipe on list item.…
Shreeya Chhatrala
  • 1,441
  • 18
  • 33
1
vote
2 answers

Custom menu adapter for navDrawer?

I'm developing an app using the official android NavigationDrawer, the navDrawer has its own menu xml called activity_main_drawer.xml in the picture below: This is it in the app: Now i want to change the titles and icons for each row dynamically…
Fadi Obaji
  • 1,454
  • 4
  • 27
  • 57
1
vote
2 answers

android studio custom adapter OnClickListener

I'm struggling with this code and every time i run it it crashes so i went back to it's normal state where i finished the custom adapter and connected it to the listview and the program ran very nicely, then i tried adding an intent to open another…
1
vote
1 answer

Android: constructor ContactsAdapter in class ContactsAdapter cannot be applied to given types

i'm trying to populate a ListView with a ArrayList this is my code: ArrayList results = mapper.readValue(response.toString(), new TypeReference>() { } );//results are coming OK …
emboole
  • 501
  • 6
  • 23
1
vote
2 answers

JSON response not printed properly in android Listview using volley

I have a json response which i printed in a listview.It is printed the values from json but all value not printed correctly.Some json values are printed in wrong place. JSON Response: ``` [ { "HouseNo":"33333333", …
Adi
  • 400
  • 8
  • 25
1
vote
0 answers

Listview with textviews and checkbox, custom adapter

I have a expandable listview that when clicked, switches to a tablayout with 3 tabs, each tab containing a listview. Depending on what item was clicked in the expandable listview the 3 tabs will populate different data. I have set it all up so I…
LBJ33
  • 425
  • 11
  • 29
1
vote
0 answers

Alphabetical contact list just like android device contact list with user name and his image.

I am sharing here a screenshot. I just want to create very same contact list here as android device contact list (here as my screenshot), that looks in alphabetical order. I tried using section indexer and without using section indexer, but it is…
Mayank Pandey
  • 79
  • 1
  • 13
1
vote
1 answer

Downloading images and text from Parse and adding to ArrayList provides unexpected result?

I've been working on an app that downloads thumbnails and text from Parse and adds it to ArrayLists which are then displayed through a custom adapter for a ListView. The issue here is, the thumbnails for the required content is sometimes misplaced.…
1
vote
2 answers

Using a string array with a custom adapter to listview?

So i have a string array that I have. I am trying to pass each individual item from that string array to the custom adapter. I'm having trouble figuring out how to use the string that i pass in the custom adapter? String[] that I pass String…
AndroidDev21921
  • 695
  • 1
  • 8
  • 21
1
vote
1 answer

How to display images with title and description from server in custom list adapter in android

I am creating an app using PHP & Mysql that is displaying custom list view with image, title, description and price in tab fragment. To achieve this, I have created a ProductTabs class with ItemList AsyncTask inner class this is being used to fetch…
Ankit
  • 627
  • 1
  • 9
  • 22
1
vote
1 answer

populate GridView using custom ArrayAdapter won't load the first time(asynktask)

The problem is i can't figure out why the grid won't filled with the images, the first time i run the app. If i do refresh or change to landscape mode the images load and the app works fine. I assume it has to be the List that i gave to the Adapter,…
1
vote
1 answer

RecyclerView does not update a private field in onBindViewHolder after notifydatasetchanged()

I have a RecyclerView in which I have to load different data based on a value which I am changing in an updateList method. Following is my code: public class PerformanceAdapter extends RecyclerView.Adapter
Sarfaraz
  • 324
  • 1
  • 3
  • 13