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
votes2
answers320
viewsPOST using Retrofit is not returning to the Onresponse function
My application is made with Kotlin Retrofit and Gson. I have several gets to fetch information and work normally, manipulate the data returning in Onresponse and ok, works normally. But when I run…
-
0
votes2
answers1682
viewsIs it possible to have a round button without changing the android:background attribute?
I have in the directory res>drawable>fundo.xml the following code: <?xml version="1.0" encoding="utf-8"?> <shape xmlns:android="http://schemas.android.com/apk/res/android"…
-
0
votes1
answer264
viewsPWA - Add start screen does not work on localhost
I’m trying to make my mobile site appear the "Add Home" button, but it doesn’t work at all. My files index php. <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8">…
-
0
votes1
answer54
viewsRecyclerview is displaying entire json array instead of object
Inside recyclerView everything is being displayed correctly except the "name" (Notifier > name) When I use String creatorName = hit.getString("notifier"); it shows the entire "Notifier" object.…
-
0
votes1
answer43
viewsIs it possible for a single button to change Imageview A to B, C, D... ? - Java/Android
Is it possible to change the same button Imageview A to B, C and so on? In the same onClickListener? My first attempt, knowing it wouldn’t work, was mNext.setOnClickListener(new…
-
0
votes1
answer152
viewsError opening dialog with recyclerview, when adding click on list item
Error: RecyclerView﹕ No adapter attached; skipping layout I saw several items really similar to this error here, but none solved my problem. The list is loaded normally, only after adding the…
-
0
votes1
answer103
viewsUse Highest Precision Possible on Android GPS
I’m building an app that by going through a "line", defined by an interval of latitudes and longitudes, recognizes the passage and displays it in a View. But I noticed that when passing through the…
-
0
votes1
answer141
viewsError while receiving json from Android Studio objects
Good afternoon guys, I’m having trouble getting an array of objects and show in Listview on android. In case the class that is giving error is this: public class HTTPCarregaLista extends…
-
0
votes1
answer45
viewsGrab image from the gallery
Manifest <uses-permission android:name="android.permission.INTERNET" /> <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" /> <uses-permission…
androidasked 5 years, 9 months ago Maico Rossarola 41 -
0
votes0
answers46
viewsAPP Stopping to work
What’s wrong with the code? In the IDE it appears that there are no errors but when I open the app it closes and appears the message "app stopped". public class BallControl extends Activity…
-
0
votes1
answer54
viewsThread Android error that is crashing the app at the time of opening
I’m doing an initial project to test the functionalities of the Speechrecognizer library from google for android, but at the time if climbing the App I’m having problems, in this case it just closes…
-
0
votes0
answers43
viewsCalculate button closes application
I can’t understand why the Calc button makes the application close instead of calculating and showing the result in the textview. package com.example.cc; import…
-
0
votes1
answer71
viewsHow to create a Fragment by clicking a button?
I have the following Fragment: public class ListaBimestresFragment extends Fragment { public ListaBimestresFragment() { // Required empty public constructor } @Override public View…
-
0
votes1
answer453
viewsHow to pass double type variable through Bundle class?
I cannot pass a textview value from an Activity A to Activity B to perform some calculations. I tried through the putExtra method to pass variable of type string and then convert to double and could…
-
0
votes1
answer56
viewsPause running on an Android Service
I am developing an Android app where there is a IntentService to read a file. Each line of the file represents a record that must have a specific format according to the requirements of the…
-
0
votes0
answers172
viewsIonic 3 displays "App not installed. The package appears to be Corrupt."
I’m trying to install the apk on 2 different devices (Galaxy and LG), but both are displaying "App not installed. The package appears to be Corrupt.". Earlier I was trying to include Google Login in…
-
0
votes1
answer418
viewsChange text color in a Listview (Android)
Hey, guys, I’m having a little bit of a problem. I’m trying to change the color of a text inside a standard Listview android, however, it does not change. I tried changing the color in Layout,…
-
0
votes0
answers38
viewsHow to check if a button is visible during Activity creation?
My screen has a button and a FAB that do the same thing and a scrollview, in case the scroll happens, I check if the button is visible or not, if it is visible, I hide the button. Okay, for the…
-
0
votes1
answer88
viewscom.google.firebase.database.Databaseexception: Failed to Convert a value of type java.lang.String to long
Error I’m wanting the Android app to take the data from Firebase and show them in a list and this is the error. com.google.firebase.database.DatabaseException: Failed to convert a value of type…
-
0
votes1
answer176
viewsuses unchecked or unsafe Operations
I am developing an application in Android Studio with Firebase that is presenting the following error uses unchecked or unsafe operations…
-
0
votes0
answers69
viewsVolley: onErrorResponse is returning the error as null
My server is registering normally, but when trying to send a record to register using Volley, it drops to onErrorResponse and the object error.getMessage() is returning null. My java code: private…
-
0
votes1
answer57
viewsListview with Arrayadapter
Hello guys I’m new in Android and I’m with a question of data overwriting in listview that I haven’t been able to find yet. I have a Tabbed with 3 tabs, and when clicking the first time tab the…
-
0
votes3
answers298
viewsCreate table in Mysql using Laravel
I need to create a table with Laravel using the migrate command, the table would currently only have id. Normally two tables would be created, one with the name of the database I put containing the…
-
0
votes1
answer73
viewsHow to handle data entered into a fragment of a Tabbed Activity in Android Studio
I am learning to develop using Android Studio and I am with a beginner’s question: which class I perform data processing from a click of a fragment in a Tabbed Activity. To illustrate simply, I…
-
0
votes1
answer356
viewsCannot resolve method
I’m making an application for Android in which there is a Fragment to add a task (with title and description), and a Fragment that lists all the tasks stored in a Singleton. In Tasks Fragment when…
-
0
votes1
answer50
viewsHow to remove margin top from Imageview
Hi, I’m creating an app, and I have an Imageview with the id ivthumb that’s at the top but for some reason it doesn’t stick to the top and gets a little space. Can anyone help me solve this problem?…
-
0
votes2
answers308
viewsAndroid internationalization - Developing in Android Studio
How should I apply internationalization to an Android app,using various languages? I need to develop an Android application where the original words in Portuguese should be translated into the…
-
0
votes1
answer120
viewsMake the Tostring() method return two fields separately from a typed object
I need to get the Tostring function to return the size and color separately, as I am filling a spinner with them. A spinner is filled with colors and another with size. However if I put: public…
-
0
votes1
answer235
viewsHow better is text-to-Speech in my android app, not respecting the punctuation marks?
app already speaks what I write, but if I write a question with punctuation mark (?) does not pronounce as a question, the pronunciation is very fast, how do I improve it? public class MainActivity…
-
0
votes1
answer56
viewsSearch String Random in Sqlite and then show the Result on the Screen with button
// Create Database. final Sqlitedatabase bankDados = openOrCreateDatabase("Table name", MODE_PRIVATE, null); // Criar Tabela. bancoDados.execSQL("CREATE TABLE IF NOT EXISTS questions(id…
-
0
votes0
answers29
viewsI can’t solve a notification line
The error is on the line: notification.setLatestEventInfo(context, contentTitle, contentText, contentIntent);. I couldn’t fix it. Any change I make makes a mistake. // Define Notification's message…
-
0
votes1
answer32
viewsen - Http Post request error Ionic Probleme No 'Access-Control-Allow-Origin'
I’m having problems with the source of access on Ionic 3 I’ve already enabled header('Access-Control-Allow-Origin: *'); in PHP and apache .htaccess however the error continues to persist, I did some…
-
0
votes1
answer118
viewscompare Array with another Array com for in Java
Everybody, Good afternoon. I am wanting to compare 2 Array, where 1 array has randomly set value. I want to use for so I don’t have to repeat 100 times. But I don’t know, because it always shows me…
-
0
votes0
answers277
viewsClick Effect on Android Button
Hello people I have the following situation; boot selected.xml <?xml version="1.0" encoding="utf-8"?> <shape xmlns:android="http://schemas.android.com/apk/res/android"…
-
0
votes0
answers168
viewsImage in Drawer updating several times
I’m building an application with React Native and React Navigation, I’ve made all the settings and it’s working, however, when Drawer is triggered the image is updated multiple times without causing…
-
0
votes0
answers15
viewsNullpointerexception when displaying Notification with Pendingintent and Broadcastreceiver
I am consuming an API and called Broadcastreceiver whenever the user connects to the internet. However, when displaying the notification is appearing: "java.lang.Nullpointerexception: Attempt to…
-
0
votes1
answer24
viewsButton in the Spinner reset Mainactivity in a Dialogfragment
I have two buttons in Mainactivity, the first opens a custom Dialogfragment with some spinners and the other button resets the spinner of this Dialogfragment. When I click the reset button it calls…
-
0
votes1
answer34
viewsUse findViewById in Android Studio’s standard Mapsactivity
I’m using the standard Maps template available on Android Studio, and in the activity_maps.xml added a EditText with the id towhere. In the Mapsactivity class I just added a…
-
0
votes1
answer46
viewsGooglemap does not redenrize the map in Ionic3 app on Android and iOS platforms
I developed an Ionic 3 application and implemented the Googlemaps API, when I run the command Ionic Cordova run browser the map works perfectly, but when I will perform the test on Android or Ios…
-
0
votes1
answer159
viewsAndroid Studio emulator does not start
Is returning the following errors: 03:05 Emulator: emulator: ERROR: x86_64 emulation currently requires hardware acceleration! 03:05 Emulator: Warning: Quick Boot / Snapshots not supported on this…
-
0
votes2
answers105
viewsChange Textview with Listview event
I would like to change the total value whenever an item is changed... Class that sums up: public class Somar { private List<Carrinho_Item> lista; private double total = 0; public…
-
0
votes1
answer468
views(Android Studio) Webview loads the page and does not open
I am making an application that gathers some sites, but some of them keep clicking on Webview and does not open. As an example I will use the Urpay. I’ve seen this site being opened by another…
-
0
votes2
answers235
viewsHow to convert byte[] to mp3
I’m writing an app where I have a list of byte[] and need to create files .mp3 from these byte vectors. When prompted, the app zips all these files into one file .zip, but later the player is not…
-
0
votes1
answer808
viewsHow to clean the data stored in memory, in cache or then reset an application (App) in android studio?
I am developing an application in android studio and need to solve this problem. I am using an internal database in Sqlopenhelper to store the products chosen by the user and show in a shopping…
-
0
votes0
answers70
viewsShare generated image
Hello, everyone, I’m new to the forum but whenever I can I follow some topics. I have an Android application where it generates a bitmap and I would like to share this bitmap via Whatsapp or email…
-
0
votes1
answer921
viewsOpen pdf document via Intent?
I have an application that generates a pdf through a button and when clicking on the button opens a alertdialog where I name my file and therefore opens a snackbar with the title " Do you want to…
-
0
votes1
answer51
viewsHow to share Bitmap Generated Image
Staff would like to know how I share an image generated within the app, in the scope of the app the person writing in the text view captures and generates an image would like to share that image via…
-
0
votes1
answer1246
viewsError: illegal Character ' ufeff' - encoding "UTF-8 without BOM"
I’m in the process of migrating from an Android project created in Eclipse to Androidstudio. When trying to compile after migrating, the following error appears: Error:(1, 10) error: class,…
-
0
votes1
answer81
viewsFilenotfoundexception - Android Studio
I have the following code: String f = getStringFromFile(Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_DOWNLOADS) + "/PagamentoLio.json"); String getStringFromFile (String…
-
0
votes0
answers67
viewsApp Crash When Receiving Push Notification
The app is crashing, stopping, when I get a push notification. This is happening on Android 8.0 (Oreo) or higher. I see you’ve changed a policy, but I’m not getting it right in my code. I’m using…