Most voted "android" questions
Android is an operating system for mobile devices developed by Google and the Open Handset Alliance. Use this tag to reference questions related to programming for Android and be relevant only to this operating system. Use the [android-subject] tag instead of [subject] alone.
Learn more…8,935 questions
Sort by count of
-
0
votes1
answer182
viewsHow do I disable the stagehand template when creating a web flutter project?
I’ve tried to disable using the command pub global deactivate stagehand , however I cannot create any project if this template is not enabled. Vscode asks if you want to activate it using the…
-
0
votes0
answers22
viewshow to create a directory on android system?
I’m using the following code to create a directory when the user presses a button inside a Fragment, but it’s still not working, and I don’t know why. File dir = new File("/novaPasta"); try{…
-
0
votes1
answer324
viewsHow to convert Jsonobject to a java class
Greetings to all, I’m developing an app that takes the return of a webservice to be used in this application as login data among others. I would like to ask for your guidance on how best to convert…
-
0
votes1
answer139
viewsConfigure Cardview in Recyclerview
I have a RecyclerView and use with CardView, the problem is that in one version of android the visualization is different from the other. I would like the visualization of android 9.0 to be the same…
android android-studio android-layout android-fragment android-adapterasked 5 years, 4 months ago Ari Melo 131 -
0
votes1
answer38
viewsHow to add a Chip (Filter type) dynamically (via code) ? (Kotlin)
I need to add Chips Filter type (image below) dynamically Attempt 1 I tried to create the Chip in a totally dynamic way: fun onAddChip(name: String){ val chip = Chip(this) chip.TYPE = Filter //Eu…
-
0
votes0
answers57
viewsHow to recover mouse pointer position on android
I have an Accessibility service that captures events touch the screen, and I have a USB mouse connected to the Android device, I would like to know how I can recover the mouse position on the…
-
0
votes1
answer87
viewsCheck Internet status on API 29 (Anroid Q)
Good afternoon, I have the following method to check if the internet network is active at that time: public static boolean isNetworkAvaliable(Context ctx) { ConnectivityManager connectivityManager =…
-
0
votes1
answer40
viewsProblems with transparency in android studio
Hello, I have an APP in android studio that has a Linearlayout with transparency but the children of this Linearlayout are also inheriting transparency, and I did not want, as I do for only the…
-
0
votes2
answers66
viewsHow do I click on the listview and open an activyity?
I need to click on the view list and open a new activyte with the person’s name. Code: import android.content.Intent; import android.os.Bundle; import android.os.StrictMode; import…
-
0
votes2
answers1387
viewsError running React project Enable "A problem occurred Configuring project ':app'" on Linux Manjaro
I was installing the React Native following the facebook steps, and then when I went to test with the command React-Native run-android happened this error. I’ve set up the android SDK in android…
-
0
votes2
answers86
viewsProblem inserting data into Sqlite and updating Recyclerview
I’m having problems in my Sqlite bank where I created a method in my DatabaseController.java who is called recuperarUltimoDigitado() - this method retrieves the entered value and then updates the…
-
0
votes0
answers1129
viewsError while trying to install the application in flutter on physical mobile
I’m having trouble installing my application on my physical phone(Redmi 6 note PRO), I’ve done some tests and the problem is in the plugin authentication with facebook, flutter_facebook_login, if I…
-
0
votes1
answer138
viewsWhy does my service overload the device?
I am writing an app that has a Service whose role is to take screenshots at 15-second intervals, using an Asynctask. This service, however, overloads my device in such a way that, after a few…
-
0
votes1
answer104
viewsConfiguration of the Notificationcompat
I have a simple app to send Notifications, vibrate, and tap on receipt. On my android 4.3 it works, on another my mobile with android 9 it just touch, does not show notification and neither…
-
0
votes1
answer278
viewsClose app upon checkout
Hello, I have an app, it comes down to: a Activity and a fragment. To activity calls the fragment through the onCreate: Code of Activivity who calls the fragment: @Override protected void…
android android-studio android-activity android-fragmentasked 5 years, 3 months ago Aristófanes Melo 89 -
0
votes1
answer43
viewsProblems with listview context menu with spinner
I’m having a problem opening a context menu in a listview that has a spinner. I registered my list on onCreate: registerForContextMenu(lista); I created the menu and added its Reader: @Override…
-
0
votes0
answers417
viewsDoubts onPressed integration with Google Maps Flutter
I set up a canvas and I’m having a hard time doing something On the buttons I wanted to put to work onPressed linked to the google maps API. Like, when I click on one of the buttons, it will tell me…
-
0
votes1
answer253
viewsSave a list to Sqlite
I have a list of products and use recycleViwer to list them. I want to take these products and save them in the database. Being honest, I can’t do it! I’m researching but I can’t find content. I’m…
-
0
votes1
answer119
viewsDisplay the contents of a button and make it disappear after a period
I’m totally new with android studio and I’m trying to create a little memory game, the game consists of a series of buttons, a row 4x4, all buttons appear being a "?" when you click the button it…
-
0
votes1
answer214
viewsFragment screen to call another screen Fragment
I’m in a fragment, and in that fragment I want to call another screen which is also a fragment. I’m using recycleview. If I try to call one activity, I can, but I can’t call a fragment. See the code…
-
0
votes1
answer55
viewsDynamically pick up color
I created some colors in the file colors.xml <color name="colorBackground1">#5c6bc0</color> <color name="colorBackground2">#1e88e5 </color> <color…
-
0
votes1
answer37
viewsPassing the Parameters of a Fragment that uses json for another Fragment
I have a screen that searches by name through an Edittext. And when searching by name it brings me a Recycleview with its results. And when I touch an element of the result, it goes to a Fragment…
-
0
votes1
answer120
viewsDefault Activity not found
I was making an app and at one point came across the error Default Activity not found. I tried to undo the changes and the error persisted . Trying to fix it I noticed that all the files .xml…
-
0
votes1
answer32
viewsDynamically change the pattern color of a text in a standard listViewAdapter?
I have the following code: String[] hours = new String[]{ "0:00 da madrugada", "0:30 da madrugada", "1:00 da madrugada", "1:30 da madrugada", "2:00 da madrugada", "2:30 da madrugada", "3:00 da…
-
0
votes0
answers33
viewsApplication terminates on start, error occurs only on Android 9.0
Eae personal, I have an application that works normally in all versions of Android, however in Android 9.0 (Pie) starts everything normal displaying the Splash Screen but when going to Mainactivity…
-
0
votes1
answer51
viewsAndroid socket does not come out of the while, why?
After sending the event I have to close the program to send another event through the socket. I realized that it is not closing, gets stuck in the while paps go through the…
-
0
votes0
answers40
viewsHow to create a dynamic layout of equations system on android
I’m creating an application for Android that solves systems of linear equations in which the user defines the number of equations, and generates a system of Equations, where the user needs to define…
-
0
votes0
answers118
viewsLocation loops only above API 23 version Android 6.0(Marshmallow), why?
The problem is that in the above versions (tested on Apis 23, 24, 27) ,(on API 29 ta working) the deburger shows hundreds of passages by onLocationAvailability 'Cause I put a log. This always…
androidasked 5 years, 2 months ago user65509 -
0
votes1
answer65
viewsBack to the main Fragment from a button
Hi, I have an app that uses NavigationDrawer, I have a fragment that has a AlertDialog, and in it I have two send and cancel buttons, no cancel wish back to the desired main Fragment. I managed to…
android android-studio android-activity android-fragmentasked 5 years, 2 months ago Aristófanes Melo 89 -
0
votes0
answers71
viewsHow to start a class in the same. java file?
I am new in this part of compilation for Android APP, I would like to know how to start a class q is in the same java file, for example: my 'Mainactivity', already declared the button that should…
-
0
votes1
answer215
viewsHow to pass data through an Intent to Main Activity?
I’m developing a small android app to exercise what I’ve already learned. The application consists of two Activity’s, Mainactivity and a second Activity. On Main I have a textView and a button,…
-
0
votes1
answer70
viewsUnable to use sdk dialogFlow java together with firestore - Dependency failing
I need to use the dialogFlow sdk along with the firestore sdk. In separate projects I can use normally, but when I join them, there is a dependency failure. My build.Radle: apply plugin:…
-
0
votes0
answers418
viewsHow to block app minimization and closure?
I’m developing an app in java, Android Studio, which will serve as a menu, on tablets. I would like to block the minimization and closure of the same(I believe that the owner of the establishment…
-
0
votes1
answer146
viewsCould someone explain to me how this new Navegation Drawer works?
I’m starting to study android, and after update 3.5 of android studio the template of Navegation Drawer has changed a lot and as I’m starting to study,someone could explain to me where the Fragment…
-
0
votes2
answers189
viewsDowngrade project version in android studio from 6.0 to 5.0
I developed a project in android studio API 23: Android 6.0 (Marshmallow). However, the project should be developed for android 5.0. I would like to know if there is the possibility of doing some…
-
0
votes0
answers28
viewsAndroid Unit Test -> Problems mocking a method that has static class
I am doing unit tests of my Viewmodel and have a method that saves the data in Firebase generating an id internally with the help of the Base64 class. In my class structure I call the…
-
0
votes1
answer168
viewsPass multiple attributes to a Command Parameter in Xamarin Forms
I have a function that is a List, I have a button and I wanted to pass 2 parameters from this list to this button to redirect to the next screen, but I do not know how to do this, because…
-
0
votes1
answer117
viewsIs it possible to make edits in . apk?
I developed an app in java, android studio, and will publish it on a web platform of my own (also developed in java). Only those who have access to this platform are licensed customers and this…
-
0
votes1
answer182
viewsIn a Flutter application on Android Studio an error message is displayed when modifying something in the build.Radle
FAILURE: Build failed with an Exception. This error occurs when I modify something in the build.Radle of the "app" folder of some Flutter application in Android Studio. So, just clicking on the…
-
0
votes0
answers44
viewsSending JSON to web-service via Http
I have a question that I believe to be simple to solve, I have a web service that feeds my App, I can request this information but I can’t send information, the closest I have so far was: JSONObject…
-
0
votes1
answer57
viewsAndroid - Arraylist is not being filled
I created a code with a contact class public class Contato { private String nome; private Integer foto; private String ramal; private String setor; private String email; public Contato(String nome,…
-
0
votes1
answer21
viewsReceive Email with Android Java
I have this simple screen <?xml version="1.0" encoding="utf-8"?> <androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"…
-
0
votes1
answer57
viewsError in android genymotion emulator (linux): Httpexception: Connection closed before full header was Received, Uri = http://127.0.0.1
I have the following error while running an android flutter project, I noticed that if I leave my code without letters in the text class, the code will run. An example: import…
-
0
votes1
answer81
viewsstopService() not for service
I’m studying Services on Android, I can perform the same in a simple test just for understanding, but I can’t stop it in main Activity at all. I believe I’ve tried everything. I tried to put…
-
0
votes1
answer116
viewsanuncio admob no Fragment android studio
I am trying to add banner ad in my app by Fragment, but I could not, nothing appears. What can I do to solve? fragment_inicio.xml <androidx.constraintlayout.widget.ConstraintLayout…
-
0
votes0
answers31
viewsImage is recorded in the folder I created and another in the camera gallery
I have the following problem I have an app, which takes photo however and Torola device is recording in the gallery in addition to record in the folder I said it would. Intent photo = new…
-
0
votes1
answer2709
viewsError running build p/ android - IONIC 3
I’m working on an application with Ionic 3 and when I tried to turn the remote ionic cordova build android, a number of errors occur. Console indicates an issue with environment variables…
-
0
votes1
answer71
viewsHow to open Webview in the last URL accessed
I’m making a web app with just one nick login. Every time someone opens the app, they only enter the variable url where the page asks for the nickname, but I wanted it to save the last URL to access…
-
0
votes1
answer51
viewsListview repeats the last record inserted in Sqlite across the list
I’m learning how to develop mobile for Android using Java and started studies to persist data. Everything was fine until I tried to fetch the Sqlite data and insert it in a listview: the whole list…
-
0
votes0
answers20
viewsHow can Firebsae Realtime NOT load previous data after logging out of the account?
At the beginning of conversation, I am very new in android Java development, however I have a problem with firebase Altime in my application. I turned on . setPersistenceEnabled(true); for it to…