Questions tagged as 'android'

2
answers

Failed "You need to use a Theme.AppCompat theme (or descendant) with this activity." when opening an Alert Dialog on Android

Good morning classmates! In the middle of the project that I am developing on Android, I want that when you click on an image, when you push it out, a dialog box appears asking for confirmation: This is the code I have to open the image:...
asked by 10.06.2016 / 08:17
2
answers

JSON Parser check integer is Null in Java Android

I get a JSON that sometimes the numeric fields have value or null : { duration: null } Right in the sentence: jArray.getJSONObject(id).getInt("duration"); The error occurs: W/System.err: org.json.JSONException: Value null at...
asked by 21.01.2016 / 15:53
2
answers

Calculate age using EditText and not using Calendar

How can I calculate the age (including day and month) using an EditText? Right now I do it using a Calendar, but I would like to write the date 23/01/2017 (Example) in the EditText to calculate the age. EditText that I want to use to calculat...
asked by 23.01.2017 / 16:38
2
answers

How can I take a break when writing a file on Android?

I have been having problems with writing files on Android, I need to fill out a form and then store it in a PDF or txt file, for the moment I am trying it in txt but I can not write more than one line in it, due to that when trying to write on i...
asked by 05.01.2017 / 20:31
1
answer

Android Permissions with Google Play Permissions policy

I want to comment this time and ask for your collaboration in Android, since last year 2018, I have received messages from Google about an application that I have in the playstore that I use to send SMS to a GPS device. Apparently Google chan...
asked by 04.01.2019 / 17:47
1
answer

Android: How to use ImageButton?

I am something new in this of Android Studio, and now I want to put an Image Button but at the moment of coding it my App crashed when I try to compile in my cell phone. Any help? XML: <ImageButton android:id="@+id/telefono_ni...
asked by 28.04.2018 / 15:37
5
answers

Difference between finish () and onBackPressed ()

Well, as the title indicates, what is the difference between the method finish() and onBackPressed() ?     
asked by 28.10.2016 / 13:22
3
answers

Locale returns to default

I am trying to change the locale of an app so that it is the user's choice through the following code public static void updateLanguage(Context ctx) { SharedPreferencesManager sharedPreferencesManager = new SharedPreferencesManager(ctx);...
asked by 29.11.2016 / 09:57
2
answers

Glide, I get the error message: "java.lang.IllegalArgumentException: You must not call setTag () on a view Glide is targeting"

When trying to load an image using Glide , inside an ImageView, ensuring to have the path of the image in urlImage and the instance of the ImageView in imgZoom , this is my code: private View individual(LayoutInflater...
asked by 10.02.2016 / 04:32
1
answer

Difference between alertDialogStyle and alertDialogTheme

Well the title is very clear, what is the difference between alertDialogStyle and alertDialogTheme ? I have been looking at the documentation of Android developers but it is not very clear to me, could you explain it to me better? <...
asked by 17.10.2016 / 18:05