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
answer121
viewsWhen I charge my App class is not recognized
It says that Badeview does not exist in the current context in this line of sham.g.Cs [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Xamarin.Forms.Build.Tasks.XamlG", "0.0.0.0")] private…
-
0
votes2
answers974
viewsHow to capture date value with Datepicker
I have a Datepicker in my project and would like to know how to get the value of the chosen date after selecting it. I know that on the calendar: calendarView.setOnDateChangeListener(new…
-
0
votes1
answer115
viewsIonic 3 - Admob has Error when placing it in APP
When I put Admob in my Ionic application it looks like the picture below: What would be the mistake to n be showing the ads ?? Code I use: displayBanner() { if (this.platform.is('cordova')) { const…
-
0
votes1
answer115
viewsFirebase - Why it does not execute addOnCompleteListener code
How does addOnCompleteListener work, it is not a System that will be called when the signInWithEmailAndPassowrd operation is executed? It enters a correct login and password and click on the button…
-
0
votes0
answers128
viewsAndroid - java.lang.Nullpointerexception
I’m making an application to send some characters by Bluetooth to an Arduino, however, I can not save the mac address of the module used. The mistake happens right here: EXTRA_ADDRESS =…
-
0
votes1
answer608
viewsPass Activity variable to javascript function in Android webview
I’m trying to pass a variable that’s in Searchview on Toolbar from an Activity to a javascript function of a webview loaded html page, but I’m not getting it. I have been researching for two days…
-
0
votes1
answer40
viewsSeachview search fragment data
In the application has Toolbar and 2 tabs through the Tablayout with 1 fragment in each tab. I want to put the Materialsearchview library to implement the searchview that will be done by searching…
-
0
votes2
answers78
viewsHow to simplify clicks on buttons in Java for Android?
I’m starting to have a lot of buttons in the same Activity and as much as they are simple commands, the code is getting big, and it will get even bigger. I wonder if there is a way to simplify by…
-
0
votes1
answer52
viewsHow to use ""Quickcontactbadge" by passing a number to the "assignContactFromPhone" method per parameter?
Guys, I was practicing a little bit here (I’m a beginner) and I came across the following problem: When I try to use a "Quickcontactbadge" passing a number per parameter to the…
-
0
votes1
answer547
viewsProcessing decimal places Edittext
I need to set a number of decimals for a EditText on Android. For this I used a InputFilter as shown below: public NumeroFormatado(int digitsBeforeZero,int digitsAfterZero) {…
-
0
votes1
answer114
viewsPick up an item from Recyclerview and associate one class to another
The thing is, I’m making an app for reading books that is worth as a final note, and I want to do this: after registering a book, I would like to add comments on it. When touching an item from…
-
0
votes2
answers487
viewsBreaking lines in a list from the bank
I have this Dao that does a search to the Sql Server Database public String nomeTabela() { String nomeData = ""; String nomeAlarme = ""; String nomeRecebe = ""; ConexaoDao conexao = new…
-
0
votes2
answers146
viewsRemove accent on search using android searchview
I wish that when it was picked up on my listview João were shown João, Joao, joão, joao. I’m using a searchview, I read something about Normalizer but n understood very well. @Override public…
-
0
votes1
answer554
viewsMixing versions can lead Runtime crashes
I’m having a problem with com.android.support:appcompat-v7:26.1.0. Anddroidstudio says that: All com.android.support Libraries must use the Exact same version Specification (Mixing versions can lead…
-
0
votes1
answer330
viewsBlock days Datepickerfragment Android Studio
I need to block the days of Datepickerfragment, the days that may be released to select, will be counted from the current date + 3 days and the following days should be locked to select, or else…
-
0
votes2
answers84
viewsData sent from one Activity to another arrives null
My Activity I’m displaying the database data in listview @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState);…
-
0
votes1
answer831
viewsHow do I send notifications (push) to a specific user (from the application) from Firebase?
I’m developing applications using the Ionic framework. One of the big questions I have is how do I work as remote notifications (different from local notifications, easily generated by Ionic). Using…
android ionic firebase push-notification firebase-cloud-messagingasked 6 years, 8 months ago Victor Nolêto 25 -
0
votes0
answers93
viewsEvidar the change of special characters in URI writing
I’m using the google maps API in my project but I’m having a small problem. to mount the URL I am using a URI that concatenates with buildUpon like this in the example below. Uri uriBase =…
-
0
votes1
answer296
viewsOpen pdf by URL and Inputstream Pdfview
I would like the user to enter the product code (at activity_main.xml) and click the button. The screen changes (view_pdf.xml), would make a PDF download (AnsyTask) and would open on PDFView for…
-
0
votes1
answer25
viewsI was trying to take the title_bar and the application does not run!
<?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.example.ruimiguel.pap"> <application…
-
0
votes1
answer42
viewsChanging button color dynamically on Android
I have a menu, with 3 buttons, and I need to change their color dynamically in code. I’m currently doing it this way: mDrawable.setColorFilter (0xff0099cc, PorterDuff.Mode.SRC_IN); What happens is…
-
0
votes1
answer1443
viewsIntegration of SQL Server with Android
I’m having trouble connecting to Sql Server and Android. When I try to communicate, the message appears: "No address Associated with hostname." I’ve done everything I needed, already downloaded the…
-
0
votes0
answers34
viewsLong task on Broadcastreceiver, error: android.os.Networkonmainthreadexception
When I perform a task (which usually requires a AsyncTask) in the BroadcastReceiver, he accuses me of error: erro: android.os.NetworkOnMainThreadException I saw that it is not a good practice a…
-
0
votes3
answers842
viewsSave state when returning to an Activity
I have an Activity of registration with 4 fields: 1 editText and 3 Spinners. At the click of a button the data entered in these fields are recorded in the database and lead to another Activity with…
-
0
votes2
answers145
viewsHow to run request again after having permission accepted on android?
I have a button that when pressed it should open the telephone call mode with a dynamic number. This method requires permission CALL_PHONE. And when pressed the first time, it opens a dialog asking…
-
0
votes1
answer182
viewsInsert a code into Mainactivity
I just started messing with Androidstudio and here’s the deal. I have this code in my mainactivity: package com.tero.master; import android.media.MediaPlayer; import…
-
0
votes0
answers141
viewsError while compiling my project
Someone can help me to correct these errors, I found several places citing this error, but nothing works, I’m already a week trying to fix it:…
-
0
votes0
answers72
viewsW/System.err: Strictmode Vmpolicy Violation with POLICY_DEATH; Shutting down
When repeatedly opening an Activity the following error occurs: E/StrictMode: class br.com.teccity.cardapiosduchef.empresa.EmpresaActivity; instances=2; limit=1…
androidasked 6 years, 8 months ago Washington Luis 1 -
0
votes1
answer72
viewsAsynctask result
I rephrased the question again to try to clarify better the need of my situation: I need to run between asa Activity s the following operation, when clicking the button, the application sends…
-
0
votes0
answers33
viewsAndroid - app stops working when I open the camera
I have a project that there is a form that the user can take a photo to insert, this worked but due to an android update whenever I click the photo button the app to, someone knows what can be?…
-
0
votes0
answers36
viewsDo I have any risk in using parentActivity in the manifest of my android app?
I have an Activity with a text about terms of use. It can be called through a menu and opened directly. So for this reason I have put in the manifest this Activity in parentActivityName so that when…
-
0
votes1
answer62
viewsCreate objects after external server response via API
Here’s the thing, I created a php API that generates a Json. THE LINK IS THIS for those who want to view. I was able to access the link and rescue the information, because I used a Toast to show…
-
0
votes1
answer62
viewsXamarin Android WCF to after enter more than 10 times
I have an app on Xamarin android that consumes a wcf service, when I instate the service more than 10 times the service falls and you need to restart it and when it will restart the bar you need to…
-
0
votes3
answers526
viewsUTF-8 sending by POST does not work
Have the following connection class: public class Conexao { public static String postDados(String urlUsuario, String parametrosUsuario) { URL url; HttpURLConnection connection = null; try { url =…
-
0
votes0
answers113
viewsC# Xamarin: Sqlite table from Mappings classes (Entitytypeconfiguration<Class>)
I’m trying to create some tables on sqlite with VS Community 2017 (c# and Xamarin android) from classes that are defined by Entitytypeconfiguration. Below I try to better detail my difficulty. I…
-
0
votes1
answer137
viewsAndroid pass Authentication Token in header using Volley
I’m having trouble sending authentication token in header using Volley This is my code @Override public void onActivityCreated(@Nullable Bundle savedInstanceState) {…
-
0
votes1
answer96
viewsHow to extract String from a larger string separated by "/"
I have a string and want to extract a substring see in my code: String link = "lojas/RJ/Macaé/Loja Modelo/pedidos_ativos/03-03-2018-8773"; String uf =…
-
0
votes0
answers58
viewsList objects by neighborhoods
I have an object where it is possible to add a list of addresses in the address field, the goal is to list the objects according to the neighborhoods where the objects reside. Object: public class…
-
0
votes1
answer80
viewsCreate spinner with dynamic values
I’m trying to create a spinner with dynamic values. It’s making a mistake when I try to set the Adapter in the spinner, follows below the error and my code. java.lang.NullPointerException: Attempt…
-
0
votes1
answer464
viewsPass data from Firebase Database to Intent and recover in another Activity
This is the code snippet of my Fragment in which I need to pass a parameter (id of Firebase DB) through an Intent generated by Adapter.setOnClickListener: ...…
android firebase onclick android-intent firebase-databaseasked 6 years, 8 months ago Adriano Junior 1 -
0
votes1
answer477
viewsNo specific details appear in android studio when configuring application for various screen sizes
Please ask that in reply do not indicate me the link of the documentation of android to read. I am developing an application that has that be adapted to more or less 8 different inch screen formats,…
-
0
votes1
answer44
viewsExpandablelistview edittext disappearing or scrambling text
I have a problem with Expandablelistview, I have two edittext per line, every time I type something in one, and scroll the screen, when I go back or deleted or changed position. I’ll post my code:…
-
0
votes0
answers152
viewsGeofire updating background location
I’m making an application , the location system is similar to the Uber , who needs to send the location to firebase from 3 in 3 seconds , to get the current location live , but when the app is in…
-
0
votes1
answer177
viewsHow do I recover a result from within the "onActivityResult" in my Activity
I’m trying to use the camera phone as a barcode reader. I can retrieve the barcode, and see the result inside the "onActivityResult", however, I need to take the result I got, to my main function,…
-
0
votes1
answer30
viewsToolbar hiding a piece of textview
Follows code: <?xml version="1.0" encoding="utf-8"?> <android.support.v4.widget.DrawerLayout xmlns:android="http://schemas.android.com/apk/res/android"…
-
0
votes0
answers29
viewsRefresh Image
I have a question, because I’m setting the picture from Spinner’s position. Then, when you open Activity, the Oncreate method reads the position of the spinner and loads the image according to its…
-
0
votes0
answers166
viewsShow first letter textview
I’m taking the Firebase data and putting it into a Reciclerview. And I’m using the Textdrawable library to display the first letter of the text naming in a circle made the gmail app.However I cannot…
-
0
votes2
answers367
viewsUpdate android project
I have in my hand a project 3 years ago and I need to put it to run, so when I opened the project in android studio already gave the default error Gradle, I changed the line classpath…
-
0
votes1
answer125
viewsButton does not appear in an Active and appears in another
I have a problem I don’t know where it is. I have a layout that runs a video, with a button in the front, only that the button does not appear although when I click on the area of the button it…
-
0
votes0
answers760
viewsPOST request sending a String via Retrofit on Android
I need a lot of help from you, I’m wanting to make a POST request via Retrofit, send only one parameter: { "select":"select id || ' | ' ||senha_terminal,nome,login_web,null,5,null…