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
-
-1
votes1
answer57
viewsProgramming with android studio
I am having error in my project, the error that appears is the following: ->/ Error:(23, 31) error: ';' expected/ package com.example.lorenzo.pulo; import…
-
-1
votes1
answer450
viewsHow do I get the Calendar date on Android?
I got it inside the onCreate: final DatePickerDialog.OnDateSetListener date = new DatePickerDialog.OnDateSetListener() { @Override public void onDateSet(DatePicker view, int year, int monthOfYear,…
-
-1
votes3
answers405
viewsSelect only latest Mysql Chat messages
I’m creating a chat on an android app and I need to display this screen: My database looks like this: Table messages: I am making a this example query for the user who has id=43 SELECT m.dono,…
-
-1
votes1
answer849
viewsAttempt to invoke virtual method on a null Object Reference
Error: 09-12 17:13:09.088 26022-26022/costamilam.guilherme.contatosempresariais E/AndroidRuntime: FATAL EXCEPTION: main Process: costamilam.guilherme.contatosempresariais, PID: 26022…
-
-1
votes1
answer119
viewsHow to get JSON values that Okhttp generated?
This is my code public void loginRequestAsync() { OkHttpClient client = new OkHttpClient(); HttpUrl.Builder urlBuilder = HttpUrl.parse("xxx.xxxx.xx.x.xx.xxx.x").newBuilder(); String url =…
-
-1
votes1
answer148
viewsMy app does not return JSON data
I’m making an app and in a part of it the user can update the login data, just enter the screen that the data is loaded and filled, automatically. The problem is that in fact this is not happening!…
-
-1
votes1
answer52
viewsIs it possible to create a Widget with multiple configuration screens?
I have a Widget that there is only one configuration screen but want to add one more how can I do it? I know that the first screen that appears is a Activity try to open with Intent normal but not…
-
-1
votes1
answer405
viewsSwap screen (xml) with login button
I am developing an application. It has the option to login. I wanted to know how to move to another xml layout when login and password validated. The login system is almost ready. I put in the tab…
-
-1
votes1
answer278
viewsPut Firebase link on each button of the app on Android
I need the image button to get the link to Firebase to download the image of the application. I will present my App to be clearer. I have this app: I was able to use the text and image of Firebase…
-
-1
votes2
answers410
viewsHow do I lock the selected Radiobutton?
I created a RadioGroup with 3 RadioButton internal, however I cannot fit a code that makes the user when selecting a RadioButton is prevented from selecting another. <LinearLayout…
-
-1
votes1
answer481
viewsError after updating Android Studio to version 3.0.1
Hello, I just updated my version from 2.1 to 3.0.1 and this error appears Information:Gradle tasks [:app:generateDebugSources, :app:generateDebugAndroidTestSources, :app:mockableAndroidJar]…
-
-1
votes1
answer1649
viewsHow to call a method within another method?
I am developing a quiz. Using as Radiobutton response. So far I have created using the onClick method on each Radiobutton, but it is not effective. So I’d like to call every question ask1();,…
-
-1
votes2
answers162
viewsHow to pass data from one button switch to another acivity?
I’m developing a mobile app on AS that has a list of cardviews. In these cards I have a switch button that clicking on will open an Alert dialog to confirm the status change. However I’m having…
-
-1
votes1
answer201
viewsExtension method(Wait() and Status()) does not work
This is not working(just the Wait() and Status lines()) try { string url = $"http://localhost:2710/api/faturamento/{IdUsuario}/{IdGaragem}"; var uri = string.Format(url); var response = await…
-
-1
votes1
answer737
viewsAjax does not work on android
I’m making a request ajax that works perfectly on the Desktop, but when I test on android does not work, if anyone can help me jQuery(document).ready(function($){ $("#loginform").on('submit',…
-
-1
votes1
answer250
viewsReplacing the csproj is a problem?
For the second time, man .csproj.user was detonated. I don’t know why this has happened or what can influence this file. Well, this is a new project I did, using the .Net Standard. When I open the…
-
-1
votes1
answer91
viewsComparing text of items from a recyclerview
I wonder how to compare text of items of a recyclerView on android. And if the texts are the same, render the text of the entry below GONE. public void pegarTexto (){ TextView um = (TextView)…
-
-1
votes1
answer334
viewsIONIC ERROR: Ionic Cordova build android
(node:8160) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Error: cmd: Command failed with exit code 1 Error output:…
-
-1
votes1
answer47
viewsSqlitedatabase db error = this.getWritableDatabase();
public ArrayList<String> addMigracaoCadIndividual(String QUERY){ SQLiteDatabase db = this.getWritableDatabase(); return null; } java.lang.Nullpointerexception at…
-
-1
votes1
answer1242
viewsjava.lang.Nullpointerexception: Attempt to invoke virtual method 'java.lang.String java.lang.String.toString()' on a null Object Reference
I have a problem on line 141, where it says that the string is null and points out the error on this line JSONObject jsonObject = new JSONObject(response.body().toString()); However I am not able to…
-
-1
votes2
answers117
viewsHow to pass a java object array to Asynctask? My problem is that when I use this looping in Asynctask pq only comes first user [0]
ControlaBanco bd = new ControlaBanco(contexto); int indice = 0; indice = bd.contaUsuarios(); Usuario[ ] tabela = bd.organizaTabela(); String tabelaOrganizada = ""; if ( indice > 0 ) { for (int i…
-
-1
votes1
answer41
viewsCrash app when entering Landscape mode
My app has two layouts, a pro mode Portrait and another pro Landscape. When I assign an event to open another Activity to the screen button, when I turn the phone, (I put it in Landscape mode) the…
-
-1
votes1
answer152
viewsHow to Solve the Android Studio 3.1.3 Cordinatorlayout Problem?
I’m starting to study android mobile development and caught several problems with Android Studio 3.1.3. And one of them that I’m failing to fix is the rendering problem. I have tried several…
-
-1
votes1
answer548
viewsHow to display a textView of an Activity in another Activity
<LinearLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="horizontal" android:weightSum="1.0"> <TextView…
-
-1
votes1
answer149
viewsBottomnavigationview Problem: Unable to find Resource ID
Good morning, everyone, I searched several times and could not find a solution to solve a problem I am having with Bottomnavigationview. Come on, in my Activity I have the following code <?xml…
-
-1
votes1
answer207
viewsHow can I add 2 submenu buttons in Android Studio
I would like to add dynamically options to my screen menu on Android, I saw several examples, but all facing a single button. supposing that I have. override fun onCreateOptionsMenu(menu: Menu,…
-
-1
votes1
answer949
views"The app stopped working," what could it be?
Good evening guys, I’m entering the world of mobile programming, and I have a problem. At the request of a course exercise, I created a project with a layout, an Activity and a class. The project…
androidasked 6 years, 4 months ago user120478 -
-1
votes1
answer746
viewsHow to load an image from a Url into an Imageview
rs = statement.executeQuery(query); List<Map<String, String>> data = null; data = new ArrayList<Map<String,String>>(); while(rs.next()){ Map<String,…
-
-1
votes1
answer42
viewsGPS sensor locking when sensor is off
I’m making an app that reads GPS coordinates. When the sensor is on and running, the app pulls the information right, but when the sensor is off, the app hangs when I try to read the coordinates…
-
-1
votes2
answers310
viewsHow to remove url bar and buttons from a webview browser
Hello, I’m new to Kotlin and I’m using a Project in webview to mirror a website in the App. However, the only page that comes perfect is the home, the external links the App uses a Webview Browser.…
-
-1
votes1
answer109
viewsAndroid Development with Android Studio - Recyclerview is not working
I’m trying to get into this world of Android development, using Android Studio. And right at the beginning I already face a simple problem for an experienced programmer who uses Android Studio but…
-
-1
votes1
answer32
viewsImage being saved with poor quality
The following code is to save the image in a certain folder, which is taken by my application, but the image is saved with a horrible quality, even being at most "100". if (requestCode == 5) { if…
-
-1
votes1
answer95
viewsProblem with Google Play Permissions
I sent a new apk to the Google Play Store to upgrade to another application, however, on the console, in the necessary permissions section I see that the android.permission.RECEIVE_SMS permission is…
-
-1
votes1
answer4755
viewsError starting project with React Native Expo
I have version 8.12.0 of Nodejs installed in Debian 9, so I installed Expo with the command npm install -g expo-cli, that at the end returned the following alerts: Ignoring this I created a project…
-
-1
votes1
answer35
views -
-1
votes2
answers186
viewsHelp to pick up response values on Android with Retrofit
I am trying to use Retrofit to consume a resource but when using the values I am doing something wrong because nothing appears. Section in I make the search: final TextView codigoCliente =…
-
-1
votes1
answer71
viewsMove Files after FTP Upload
My code uploads all images without folder, and it’s all OK! But what is it that needs to do FTP as images are uploaded to the path: "/storage/emulated/0/PicturesGRP/enviados";, storing the uploaded…
-
-1
votes1
answer62
viewsActionbar disarranged after updating Android Studio
After update no more Actionbar appears in new projects. Androidmanifest.xml: <?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android"…
-
-1
votes1
answer623
viewsAndroid Studio Error:Execution failed for task ':app:instantRunMainApkResourcesDebug'
I’m developing an app android, when I try to run or compile my app I get the message Execution failed for task ':app:instantRunMainApkResourcesDebug'. Compiler points out that there is an error in…
-
-1
votes1
answer57
viewsError 403 in Android project with Webservice using Wampserver
After implementing Webservice in my project and using Debug to check if everything is right, it returned me the same error 403 is in the image. After searching about, I confirmed that the app’s…
-
-1
votes1
answer259
viewsHow to create a selector to choose between Camera, Gallery and Photos in Android Studio?
Speak Devs! I already gave a search, but I could not find something that would help me, anyway... I would like to create a menu similar to that of the image below. I can get camera and gallery…
-
-1
votes1
answer36
viewsError on Android
I am creating a login system on Android, but for some reason is giving me this error: Skipped 280 frames! The application may be Doing Too Much work on its main thread. Can someone help me? package…
-
-1
votes1
answer32
viewsError when changing text source - android
Hello, I am creating a login app and I want to change the source of a textView but it is giving me the following error: Attempt to invoke virtual method 'void…
-
-1
votes1
answer85
viewsI’m not able to take the Edittext value of the aux variable and compare in the if
When you type 0 or 1 of Edittext is to enter IF and does not enter. private TextView nome1; private TextView nome2; private EditText vitoria; private Button salvar; private TextView primeiroLugar;…
-
-1
votes1
answer47
viewsNullpointerexception error in the Java language using Android Studio
I’m using android studio to program apps and recently all apps I try to program, while trying to run on emulator and real device, receive the same error. 04/23 00:21:55: Launching app $ adb shell am…
-
-1
votes1
answer66
viewsAndroidstudio - Swap url for image in local project path
Good afternoon, everyone, I have a string that I use to set the image of some buttons: String imagem[] = {"https://cdn.pixabay.com/photo/2015/12121.jpg",…
-
-1
votes1
answer131
viewsUse setSupportActionBar on Fragment
I have an app that uses NavigationDrawer, I need to change the name of toolbar for each fragment. My MainActivity extension of AppCompatActivity then I can change the fragment name using: toolbar =…
-
-1
votes1
answer267
viewsSave user and password, cookie in a webview
How can I save a user and password in the android webview? On the page (web), it is requested Cpf and password, for login. After this entry, the cookie is saved vis_cod, which is a return parameter…
-
-1
votes2
answers109
viewsHow can I view BD (Mysql) images(url) in Android Studio
How can I show images (url) of the Database (Mysql) in Android Studio? Mainactivity.java package com.example.APP; import android.os.Bundle; import android.os.StrictMode; import…
-
-1
votes1
answer98
viewsListview inside Listview (ANDROID)
I am developing an application where this one has an Activity where it generates a Listview of Orders, and within the Adapter of this list of orders, I have another Listview that are the items, ie I…