15,495 questions
2
votes
1
answer
68
views
ListView inside ConstraintLayout gets pushed offscreen by other elements positioned above it
Even though ConstraintLayout in Android is not new, I have only begun to convert my older layouts over as I find time or when creating new layouts, so my experience with them is limited. They don't ...
1
vote
0
answers
54
views
How do I increase the height (thickness) of each row item in a ListView?
I am making an app with a ListView in Android Studio, but each list item is too thin. I want to be able to click each item in the list and having them be this thin will not be feasible (and it doesn't ...
0
votes
2
answers
52
views
Set background color between two items of ListView
I m building an Android application using Kotlin.
So this is the layout of my Activity
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget....
0
votes
1
answer
86
views
Scroll to needed position when user popups Spinner's list
Notice: I do NOT want to select the item, I just want to scroll to that item and let user to select.
I have an application for android. This application contains a Spinner. The spinner has quite many ...
1
vote
1
answer
294
views
How to drag and reorder list in Jetpack Compose?
Can someone help me correct the logic of reordering list. I believe the moveTodo function in viewmodel is not working properly. Reordering is working but not like how it should.
Project Structure
..db
...
1
vote
1
answer
102
views
Disable ViewCell long press loading animation on Android .Net Maui
I want to disable the loading animation shown on an Android native ViewCell when the user long presses it. I was able to disable the highlighting of the ViewCell on click by implementing the following ...
0
votes
0
answers
31
views
Dirty item view being used twice in my custom implementation of BaseAdapter
In my custom implementation of BaseAdapter I have views being hidden and overwritten on the basis of their position. One such condition is based on the last element(The ID will always be -1):
if(...
0
votes
2
answers
79
views
updating listview when data is removed from the arrayadapter
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 ...
2
votes
0
answers
49
views
ListView Items Not Displaying but Responding to Clicks in Fragment
I am using Android Studio with Java to develop an application that includes an activity containing a fragment (let's call it PromotionsFragment). In this fragment, I have implemented a sticky headers ...
0
votes
3
answers
71
views
java android listview setOnLongClickListener
To function long click, the override function is changed and there are only out of date references.
I am also use click listner.
but the onLongClick override funcion don't have position variable.
Can ...
1
vote
0
answers
44
views
How to do Song Track list with fragment in Android Studio?
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 ...
-1
votes
1
answer
63
views
listview not showing in dialog (JAVA, Android)
I'm trying to show a dialog to the user with a list in it. It won't show up on the dialog no matter what I try.
CODE:
this is in TaskInputActivity where I create the dialog and the adapter for the ...
1
vote
1
answer
67
views
Listview - Getting error while linking the items correctly in Android Java
I have linked properly the List-Adapter and the other list-item components.
It didn't getting the android:id of activity_main_cake_items.xml and giving this error.
Cannot resolve symbol 'listviewCakes'...
1
vote
1
answer
42
views
FloatingActionButton doesnt change EditText item in the LIstView
I'm trying to change the EditText in my ListView by clicking the FloatingActionButton. I want to editText.setText from an array of strings from my activity for every ListView item
public class ...
0
votes
1
answer
125
views
Android Material 3 Light theme LIstView items text hidden
I am learning Android here. My aim is to display the Cursor I get from calling SQLiteDatabase.query() in a ListView. Using a ContentProvider. I cannot see the text of the list items although I am ...
1
vote
1
answer
78
views
Android Studio - Java - Difficulty Highlighting ListView Item Background Color
Introduction:
I am encountering an issue with highlighting the background color of ListView items in my Android application. Despite my attempts to modify the background color programmatically, the ...
0
votes
1
answer
40
views
Android component to impelent a listview with tabbed headers
Is there any standard Android material view that is the best fit for the implementation of such a layout?
In this layout, I mean to have a tab group on top when one of them is touched/clicked then ...
0
votes
1
answer
74
views
Retrofit API call returning NULL data
I am calling an API using retrofit and the it is returning null.
Model class
data class Employee(
val id: Int,
val employee_name: String,
val employee_salary: Int,
val employee_age: ...
0
votes
1
answer
37
views
Sqlite android stopped processing update, delete
I have an activity with a listview and one button, I use sqlite as a database
private SQLiteDatabase db;
db = getBaseContext().openOrCreateDatabase("app.db", MODE_PRIVATE, null);
db.execSQL(&...
0
votes
1
answer
66
views
I'm making an application in Flutter but the items don't fit on the screen
I'm making an application in Flutter but the items don't fit on the screen, when I want to use ListView the position of the items get mixed up and it looks terrible, how can I edit these codes?
import ...
1
vote
1
answer
79
views
BoxConstraints forces an infinite width (listview in a Column)
I am getting an error when I add the listview builder in the column.
I am getting the following error:
this is my task widget page:
import 'package:cloud_firestore/cloud_firestore.dart';
import '...
0
votes
1
answer
37
views
Listview spinner/loader that doesn't disappear
in my xml I have a listview that I fill with an adapter.
<ListView
android:id="@+id/listPartenaires"
android:layout_width="...
0
votes
1
answer
48
views
Files prior to the installation of the app do not appear
In my code I have a ListView that lists the pdf files in the "Documents" folder on the phone that is updated when you create one, but the ones that have been created previously do not appear,...
0
votes
1
answer
117
views
How to make items of list view in this app be added to history page upon being tapped?
I am trying to build a Flutter app where I have a list view builder in the home screen, but I also want to have a history page where users can see pages they have viewed. I can not make my history ...
0
votes
1
answer
43
views
Can I use adapters without having ListViews?
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 ...
1
vote
0
answers
251
views
I am creating a module like Google Calendar's day view in my app
Creating a module like Google Calendar's day view in my app. In this app, I can select a time from a time slot. One slot = 30 minutes. Then, the user can drag that slot up and down and the selected ...
0
votes
0
answers
58
views
How to search a sentence not a word from the ListView in android programming?
In my code, searching for a word can be found very well,
But unfortunately, searching for two words or more doesn't work.
How to search a sentence (two words and more) in android programming?
My Java ...
1
vote
0
answers
74
views
Room LiveData not observing changes on inserts and updates
I have setup a simple ROOM instance in Kotlin as follows:
MODEL:
@Entity(tableName = "postinfo")
data class PostInfo(
@PrimaryKey(autoGenerate = true) val id: Int = 0,
var title: ...
0
votes
1
answer
92
views
How to enable radio button in android listview?
I want to enable radio button in android listview. I don't want to use any custom adapter to display radio button.
Here is my code:
private String[] items = {"Item 1", "Item 2", &...
0
votes
2
answers
217
views
Change recyclerview for listview?
I have a response from the database that contains a list of response-items, these response-items contain 4 different types of lists. What I want to do is ask what type of list comes in each object and ...
0
votes
0
answers
44
views
Display 10 items at a time in list view and next 10 after some scroll and so on
I want to display all the installed applications in my phone in a list view. But, I want to display 10 applications at a time. Now, when the user scrolls, another 10(from remaining applications) ...
-1
votes
1
answer
38
views
No setAdapter method on List to connect it to Listview
I wrote a program that takes data from the server using the retrofit library and displays it inside a fragment that contains a Listview.
The problem is that I don't have the setadapter option to ...
0
votes
1
answer
56
views
Android app crashing when attempting to pass linkedlist to fragment and do anything with it
I am trying to display fields of these objects in a listview which I have working and is in a fragment. My issue is with any example I have that is working it appears to be for arraylists not ...
0
votes
0
answers
20
views
Is it possible to update my listview witouth moving to first row?
I know there were plenty of similar problems there but I didn't find specific problem like that. What I expect? After I update my row by setOnItemClickListener I want to update my listview from ...
1
vote
1
answer
41
views
is not applicable for the arguments (MainActivity.Listview1Adapter, String)
I have class QuranArabUtils
public class QuranArabicUtils {
public static Spannable getTajweed(Context context, String s) {
}
}
And this is my adapter listview
@Override
...
0
votes
1
answer
51
views
Get the Margin top of a clicked item in a listview
I have a problem with the setSelection of a Listview that I fill with Adapter.
I use setSelection when I return to a list of items, after I have clicked on an item to see the detail (view2)or edit its ...
0
votes
0
answers
41
views
Deleting element from a listView removes last element instead of target element
The program is suppose to add and delete views from a list view. Objects (views) are added with an add button and deleted with a long hold pop up window. Everything works but when I delete an object ...
0
votes
1
answer
445
views
How to calculate how many items fit(visible) in screen at recyclerview?
I have a simple recycler view and their adapter
my question is that how to calculate how many items fit(visible) in screen at recycler view?
for example if my data list size is 30 and visible item in ...
0
votes
1
answer
48
views
How to click on a button inside list element of a RecyclerView?
So I have recyclerview here, and I want to delete a specific element by clicking on that element's delete button (here, the trash icon is the image button). How do I do it?
2
votes
1
answer
62
views
How to submit ListView checkbox values using a footer button?
I have a ListView which is bound to some data I have in the viewmodel. In the ListView, each row is a check box and the name of a symptom (e.g. coughing). At the end of the ListView, in the footer, I ...
1
vote
1
answer
2k
views
.Net Maui ListView is not appearing in Android
The problem is that listview header and content is not appearing on my android device and android emulator, so please what is the fix for that?
<?xml version="1.0" encoding="utf-8&...
1
vote
1
answer
126
views
Cannot capture listview itemselected
I'm trying to capture the item clicked on in a listview. Everything I've seen here deals with Xamarin Forms, I am NOT using Xamarin Forms. I build my listview and display it fine, but I cannot ...
0
votes
1
answer
40
views
Listview not clickable when adding an ImageButton (android - xml)
I have a layout for a listview item.
I added an ImageButton to the layout, as follows:
<?xml version="1.0" encoding="utf-8"?>
<FrameLayout xmlns:android="http://...
0
votes
4
answers
413
views
List<StudentModel> studentDetails = []; here StudentModel is class in flutter and i don't know how this line of code work
class StudentModel {
final String name;
final String age;
StudentModel({required this.name, required this.age});
}
this is StudentModel class
I didn't understand how the values will store in this ...
0
votes
0
answers
115
views
How to choose a category in food ordering app which opens that particular section?
I'm making a food ordering application on java using Android Studio IDE. I have designed my application in a way that it has a section called categories in which I have implemented a recyclerView to ...
0
votes
1
answer
38
views
Textview data is not being updated when called inside from function in ListView Adapter
Textview data is not being updated when called inside from function in ListView Adapter. Please help in setting binding.tvQ.text
class CustomPizzaListAdapter (private val context: Context, private val ...
1
vote
0
answers
87
views
Value of RatingBar getting changed dynamically on scroll
I'm displaying a list of food orders using a RecyclerView. Each view item has a RatingBar, so client can submit rating for the order.
Problem: When client scrolls down and goes back up, the value of ...
0
votes
1
answer
25
views
Listview-android total not reflecting correctly when item in removed from listview
Whenever items from listview are added or deducted the total should be updated. When I add items from listview the grand total is correct but when items are deslected the price of the product shd be ...
0
votes
1
answer
49
views
Android hide listview by clicking outside of it
I want to collapse or hide the listview on click of anywhere on the screen. The code is partially working. Whenever I click in the top and bottom section of the screen listview is hidden but if I ...
1
vote
1
answer
258
views
How to make notification OnItemchange when a new item is displayed in the list
i made an app using java and retrofit2 to fetch datas from the server.My listview can only display 30 item. when a new item is displayed in the listView the last one is removed automatically and the ...