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
2
votes
0 answers

Can't get the current item on AutoCompleteTextView adapter

I am creating an app that has an autocompletextview, wherein the user will see suggestions as he type just like a combobox. What I have accomplished: Create a custom adapter for the AutoCompleteTextView. When I typed a text, list of suggestions…
2
votes
1 answer

AutoCompleteTextView with Custom Adapter filtering not working

I have a autocomplete text view in my android project which is working fine but it only works if first value is entered in it. So for making it more customizable, I have added the below class public class CustomArrayAdapterWIthFilter extends…
2
votes
2 answers

How to make three level expandable List view from JSON in Android?

hi i want to create three level expandable list view from the json. I have creted expandable list view up two two level but for three level i did not got how to do please if any body don please help me to complete it. here is my code i have…
user6056187
2
votes
2 answers

How to add new feed to recycleview at same time without scroll or refresh the view?

I have an activity in which I have used Recycle View to show all items as a list. On same activity I have given functionality to add new item. Everything is working fine. Items are adding in my database and its showing in list. I have added…
2
votes
3 answers

Custom ListVIew Is not displayed an empty screen is displaying

An empty view doesn't appear when no items in the list . what is the problem? Main_Activity package com.example.android.customadapter; public class MainActivity extends AppCompatActivity { @Override protected void onCreate(Bundle…
Shubham Kumar
  • 295
  • 3
  • 13
2
votes
2 answers

Android Studio custom list view scrolling slow and causes app to stop

I have a custom adapter with just an ImageView and a TextView. When scrolling, it is very slow and if you scroll enough times, the app will eventually stop. I am thinking the way I approached this is not efficient? public class CustomAdapter extends…
ricefieldboy
  • 347
  • 1
  • 4
  • 15
2
votes
1 answer

Button located in ListView row always fired in the last row

I have a listview (not recyclerView) in which each row has a buttons,couple of textviews and an EditText. Once I click on the specific button("editTremp") I want the EditText to go into edit mode. My problem is: every time I press the button (no…
Nauruto
  • 143
  • 1
  • 12
2
votes
4 answers

How to start activity from onClick on RecyclerView in actvity

Hello Everyone I am trying to start activity when I click on RecyclerView , it is started when I add the code in the Custom Adapter , but when I write it in Activity it Just give me the position on Log .. so any help here is the code OnClick in…
2
votes
1 answer

filtered listview is not maintained as adapter which is updating every seconds

I am able to filter listview using searchview which is working fine. My listview is updating every seconds for this handler is used to update the adapter. private void nonstoprun() { handler = new Handler(); update = new Runnable() { …
user2269164
  • 1,095
  • 2
  • 15
  • 31
2
votes
0 answers

Android - Creating Listview using Custom Adapter Programmatically

I'm in learning about add view programmatically. But, I'm in confusing now. I have data, there are idpatient, idheader. Patient can have more than one ID header. When I input idpatient, it will add listview (with custom adapter) programmatically.…
flo
  • 51
  • 5
2
votes
0 answers

Selecting range of cell fall between two selected cell of grid view in android?

I am Implementing grid view with custom adapter class to show list of items. i want to automatically select the cell of grid view if it lies between two selected cell. i means to say that if user select cell let say its position is "0" and after…
2
votes
0 answers

Save togglebutton state in a custom listview

I had been searching about how to save the state of the togglebutton in a custom listview. I have a listview with a custom adapter which have a text, togglebutton and an imageview,the idea is when toggles the button the imageview changes to show a…
2
votes
1 answer

ListView Custom Adapter repeat items

Whats wrong with this adapter, when i scroll down i see repeated rows at the bottom and then when scroll up again i see also repeated rows at the top that were not exist before, and the rest of Data items does not appear the adapter: public class…
Atef Hares
  • 4,715
  • 3
  • 29
  • 61
2
votes
1 answer

TextView in custom ListView item view isn't filling parent in API 18 & 19

I have a custom list view adaptor that uses a customized list item view. The custom list item view has an image view on the left with a stack of two TextViews, a main title on top and subtitle below, to the right. What I want to happen is to have…
Jordan
  • 4,133
  • 1
  • 27
  • 43
2
votes
2 answers

SearchView displaying wrong ListView items

I am having trouble with the SearchView in my app displaying incorrect ListView items. If I type Name: ListView is displayed as expected If I type Name1: I get entries 1-2 If I type Name 2-11: I get the entry for Name1 Here is a visual: As far…
kmil
  • 243
  • 3
  • 13