Skip to main content
Filter by
Sorted by
Tagged with
-1 votes
1 answer
44 views

I was following a tutorial on creating a custom ArrayAdapter for a ListView in Android. Here is the custom adapter class from the tutorial: public class NumbersViewAdapter extends ArrayAdapter<...
minh's user avatar
  • 27
0 votes
1 answer
277 views

I have a dropdown represented by an ExposedDropdownMenu style on a TextInputLayout view element. <TextInputLayout style="@style/Widget.MaterialComponents.TextInputLayout.FilledBox....
MajinKenn's user avatar
  • 109
0 votes
2 answers
79 views

Im creating a listView and setting a custom arrayAdapter to it in my main activity. Using an onClickListener within the getView method of the adapter to try and remove the item clicked. Its being ...
user avatar
1 vote
0 answers
44 views

I'm new in android studio, just learned about a week. Before this project , I made a simple SongTrackList using main activity with no fragment, it can run smooth (click ImageButton , audio works). Now ...
willwill65pn's user avatar
0 votes
1 answer
36 views

ArrayAdapter<String> arrayAdapter = new ArrayAdapter<>(MainActivity.this, android.R.layout.simple_list_item_1, R.array.lsViewArray ); lsViewArray.XML: <resources> <string-array ...
Aditya Deshwal's user avatar
2 votes
1 answer
37 views

There is a RecyclerView suggestList and on clicking any itemView of it, we get adapterposition() which has passed through a function to get values from ArrayList used for suggestList adapter. Now, I ...
Prateek's user avatar
  • 21
0 votes
1 answer
310 views

I have the following AppCompatAutoCompleteTextView - <androidx.appcompat.widget.AppCompatAutoCompleteTextView android:id="@+id/phoneNumberPrefixTextView" style=&...
Alon Shlider's user avatar
  • 1,358
0 votes
1 answer
43 views

I receive lots of data from the backend that I need to display in 2 sections of my app in different ways, such as drawing real time graphs. 1 of the sections in question is a rectangle, that is just ...
MaDudeeK's user avatar
0 votes
2 answers
49 views

ArrayAapter Class have some constructors: When are constructors one and two used? Because we don't have data structure like input array or list at all in these constructors. If possible, explain with ...
amin's user avatar
  • 1,181
-1 votes
1 answer
175 views

This is an e-commerce app, I am facing an issue related to (adding/removing) items from the cart, The problem happened when I added two items and then if I removed one of them, The total amount is not ...
Dr Mido's user avatar
  • 2,966
0 votes
1 answer
37 views

how i can store different urls and each url acts differently when clicked by the user This is data model class import android.content.Intent import androidx.appcompat.app.AppCompatActivity import ...
Shakib Khatri's user avatar
0 votes
2 answers
60 views

(sorry for my english) I have fragment where I have an AutocompleteTextView and ArrayAdapter for it. ArrayAdapter get values from resource strings. When fragment creating first time — everything is ok,...
iwakes's user avatar
  • 11
0 votes
1 answer
42 views

I have two fragments in my Activity. Both of these fragments have unique listView, these fragments have methods that get values from database, One fragment shows used data and the other shows added ...
Gabriel Rogath's user avatar
1 vote
1 answer
921 views

I'm making an example with Android Studio and I want to add items to a List that is displayed in a Spinner. Looking here, I found this answer that helped me a lot. Basically I create an ArrayAdapter ...
Tony Valderrama's user avatar
1 vote
0 answers
95 views

I have stuck with this issue more then 3 days. I have used one RecyclerView and on recyclerview's each item have on AutoCompleteTextView. When try to search on autocompletetextview drop down not ...
Ninja's user avatar
  • 696
0 votes
1 answer
169 views

I am trying to add custom layout to change my selected item text in my spinner. But I couldn't reach my layout file with R.layout.my_selected_item in my array adapter. It is saying "Unresolved ...
menesdurak's user avatar
0 votes
1 answer
61 views

So I'm having here a problem adding a new item on a ArrayAdapter-ArrayList if I call a .add outside or inside another public void. I'm using a list view that is inside xml file and replace it with ...
leiikun's user avatar
  • 313
0 votes
0 answers
391 views

i am very new to Android Studio and making app with my WordPress website and using Rest Api to fetch data from my website , all works fine and i have added sort posts menu in my app and users can sort ...
noorapps's user avatar
1 vote
1 answer
1k views

please I'm trying to dynamically add a textitem via an EditText by clicking a button in a Recyclerview, but when I click the button to add the text in the Array related to the Adapter and I apply the ...
launchcake inc's user avatar
0 votes
1 answer
36 views

I allready created some custom array adapters and they all work. I created this one like the other ones but I keep getting this error: "android.view.InflateException: can be used only with a ...
J. Weidenhagen's user avatar
0 votes
1 answer
71 views

First time, If I add the item(click the send button) on the recyclerview, it does successfully, but if I add the item second time, I expect see the item 1,2 but 1,2,1,2 add to the recyclerview I'm ...
박성범's user avatar
0 votes
1 answer
207 views

i dont understand what is meant by R.layout or R.array in the following code, who describes how to fill a spinner with drop-down menue with a array who has different countries as its elements: adapter ...
steeveKA1's user avatar
0 votes
1 answer
278 views

I am trying to create a material exposed dropdown menu that is rebuilt when a fragment is revisited. On initial visit to the fragment, the menu is properly created (it helps create a timer). The ...
Connor Smith's user avatar
0 votes
1 answer
53 views

I have a spinner with an array adapter. The spinner is populated inside a fragment onCreateView(). spinner.setSelection(0) spinner.onItemSelectedListener = object : AdapterView.OnItemSelectedListener {...
DeKekem's user avatar
  • 1,835
0 votes
1 answer
350 views

I have succeeded pulling JSON from Reddit API but I cannot put it into my RecyclerView. I set a Log to check if my JSON is empty or null, and the Log successfully print the desired output, so that ...
HaveMercyOnMe's user avatar
0 votes
1 answer
215 views

I am displaying a product in recyclerView. I have 2 buttons + to symbolise increment and - to symbolise decrement. Once the user adds product if he clicks + product quantity should increase and if - ...
Abm's user avatar
  • 311
0 votes
1 answer
562 views

I have a TextInputLayout with AutoCompleteTextView as a 'Spinner'. I populate the AutoCompleteTextView with an ArrayAdapter like this: val adapter: ArrayAdapter<Currency> = ArrayAdapter(...
Think_Twice's user avatar
0 votes
0 answers
27 views

I have implemented a customAdapter and a listView, and everything works correctly, the problem now is that not as well as finding the id of each element created, I have to use methods in another ...
Daniele Annese's user avatar
1 vote
1 answer
94 views

I have passed data from my Activity to My Adapter. When I debug, I can see the correct data has successfully passed to my adapter, but when I attempt to use it as a string ( for example, if I want to ...
greenTea's user avatar
0 votes
1 answer
670 views

While developing Android, I wrote Adapter code for RecyclerView. But intermittently, the app closes abnormally. As a result of checking through Crashlytics of Firebase, the error contents were as ...
H.JiMan's user avatar
  • 390
0 votes
2 answers
2k views

I am new to Kotlin and/or coding. The below mentioned are the code I made to populate a List View. But as I run the code, the activity_main.xml file is inflated but the text data are not attached. ...
Jaguar's user avatar
  • 63
0 votes
0 answers
69 views

My project to make recycler View with dynamic list which is defined on Note type List on fragment in Basic Activity, first step for me to code the adapter, and cause am just at beginner level, I ...
Hany's user avatar
  • 1
0 votes
1 answer
32 views

There is an Array of String that passes from the API. What is the problem with the code? I am trying to pass that value into a spinner Call<List<ResponseSubject>> subjectOption=...
Anusha C's user avatar
0 votes
1 answer
99 views

I am creating a note-taking app for myself, I created an adapter to show notes on the main screen with a title view and text view but the app crashes when I launch it here is RecyclerViewAdapter.java. ...
ShahZaman Rai's user avatar
1 vote
1 answer
562 views

I am trying to pass a string-array from function to activity. I want to use that array into the spinner. But when I am trying to do this, I am passing an array but the function wants to pass a array ...
CHETAN's user avatar
  • 652
0 votes
1 answer
82 views

Good evening, I have an Android app with two ListView elements on a layout. between them is a TextView element. The whole is framed by a LinearLayout and a ScrollView and a ConstraintLayout. ...
amarradi's user avatar
  • 115
1 vote
2 answers
1k views

I am trying to put one piece of value in an ArrayList to my listView, below are the details. Here is the sample of the ArrayList info: private static final ArrayList<User> users = new ArrayList&...
Michael's user avatar
  • 35
0 votes
0 answers
93 views

I'm trying to use a ListView in my Fragment which is displayed by a TabViewer2. The listadapter I used is the ArrayAdapter<String>. Unfourtunately the ListVIew does not show any Items. However ...
Franek Stark's user avatar
0 votes
1 answer
51 views

I have an adaptor that I initiate in onCreate and a listview that I initiate in onViewCreated I'm trying to setAdapter but I can't pass the adapter in onViewCreated. Ive tried multiple things like ...
Marius Anton's user avatar
-1 votes
1 answer
497 views

I'm trying to create a fragment with a ListView with the id=lv and the ArrayAdapter doesn't seem to work this is the fragment code class Istoric : Fragment() { var array = arrayOf("item1"...
Marius Anton's user avatar
1 vote
1 answer
47 views

I have recyclerview contains many problem videos i have namely: when I click on any video move the list on its own down the list recyclerView = (RecyclerView) view.findViewById(R.id.recycler_view); ...
hamza's user avatar
  • 33
1 vote
1 answer
67 views

Is there possibility to have post and ads methods in two class based view? I tried to do something like this but of course it doesn't work and error it not working (layout ads) Id enter image ...
surendhar suren's user avatar
0 votes
0 answers
11 views

I have an adapter that's supposed to populate my recycler view. The adapter seems to be working because it is able to read the exact number of documents in the firestore collection. However, I need it ...
carlvindevzw's user avatar
-3 votes
1 answer
396 views

class ThirdFragment : Fragment() { override fun onCreate(savedInstanceState: Bundle?) { super.onCreate(savedInstanceState) arguments?.let { } } override fun onCreateView( inflater: ...
Chanpreet Singh 824's user avatar
0 votes
1 answer
542 views

I'm trying to retrieve an object from an ArrayList in the database but when I'm retrieving it one of the object attributes returns an empty string instead of the string saved in the database, however, ...
eyal barcessat's user avatar
1 vote
1 answer
122 views

To assign data of an ArrayList<String> alKategorien to a spinner auswahl_kategorie, I am using this snippet: ad = new ArrayAdapter( this, android.R.layout.simple_spinner_item, ...
Zurechtweiser's user avatar
0 votes
0 answers
773 views

I am a beginner in Android studio and I am trying to send an array list to a list view. I know that I am passing the correct info from my main activity to the second activity and that it is received ...
MMS's user avatar
  • 25
0 votes
1 answer
453 views

I have a TextInputLayout with an AutoCompleteTextView in it I learned from materials prencebels that the style : style="@style/Widget.MaterialComponents.TextInputLayout....
مصطفى نعمه's user avatar
0 votes
0 answers
523 views

My adapter callback is not working. I want to activate an alert dialog to pop up after the user clicks on one of the cards in recycle view. To implement the same I followed this answer. During runtime,...
darkexodus's user avatar
0 votes
1 answer
31 views

I am a bit stuck I want to be able to pass the selected row and display it in another activity... I have the following code that queries the database and fills the listview, but I can't find the way ...
Edison May's user avatar

1
2 3 4 5
88