I have several error messages in an Android Studio app using Java and I cannot figure out how to customize their appearance. I have consulted several answers on this site but none of them have worked for what I want. This is what the error message looks like. I want to change the colors of the black background, the white
Tag: android-studio
Android Studio, define a JAVA_HOME variable
I saw a video on Youtube for enhancing the performance of Android Studio. I did and now I can’t launch my Android Studio. Now it gives an error saying that “If you already have a 64-bit JDK installed, define a JAVA_HOME variable in Computer > System Properties > System Settings Environment Variables. Failed to create JVM. JVM Path C:Program FilesAndroidAndroid
App crashes due to bad notification for startforeground
i have been working on night filter app but i stuck with sdk version. My app is perfectly working on device whose sdk version is less then 23 but above 23 is not working it’s like when i tested my app in my Xiaomi which has android 9 app crashes and when i track the logcat error will through stating
How can I switch between Fragments without destroying and re-creating them? (in a static-like way)
My app uses a BottomNavigationBar to switch between Fragments, and it does it this way: I want those Fragments to be static, so their content and views do not dissapear when I switch between them. I have tried to create them inside MainActivity’s onCreate() method, but it only helps with retaining text inside EditText widgets, the rest of the views
Adding a linear layout in XML dynamically to another linear layout
Basically I created a separate XML containing a linear layout which contains a image and a textview, and I need this linear layout inside of another linear layout, where I need to add my first linear layout dynamically to the second linear layout. First linear layout, a separate XML file : Second linear layout, separate XML: Android Studio code: This
Modifying the scoring of a quiz app (android studio)
Context about the app: This is a sample 5 question test app that I made while I also learned firebase database just yesterday. The app is working perfectly and it does it needs to do, BUT what I wanna do next is that there are no right answers and each button corresponds to a score ex: Question: What are you
How to dismiss Bottomsheet on Click in ViewHolder RecyclerView Adapter?
I want to dismiss my BottomSheet on Click of cardView in BottomSheet Here is my code of onBindViewHolder I getting this error onClick I want to dismiss Bottomsheet and backto Activity. Thank you in advance =) Answer what you have done here will not work as you expect it to be :- Here you are creating a new bottomSheet Object
ANDROID STUDIO: this project is not a gradle-based project
I have downloaded this source code https://cdn.cs50.net/2019/fall/tracks/android/pokedex/pokedex.zip When I hit “sync project with gradle files”, it says that this project is not a gradle based project. I would be very thankful if someone can help me! Answer Make sure you open the project from its root directory. i.e. the directory which contains the top level build.gradle file. The missing top
How do I only allow the user to enter sensible height and weight values in Edit Text? Java
I’m making a super simple BMI calculator app using Java in android studio but I’d like to make it so that the user is only able to enter sensible values for their height and weight. I was thinking something around 50cm-220cm for height and 3kg-150kg for weight. As it stands, they can enter any number and come out with absurdly
Activity does not have a NavController set on
I basically set up 3 fragments for my bottom navigation view with all linked to activity.xml activity.xml where I put fragment tag. My Activity.java code (specifically): The problem now is that if I run that same java code using fragment tag in xml, it runs well but suggests I use <androidx.fragment.app.FragmentContainerView(linters) but on using <androidx.fragment.app.FragmentContainerView, it displays the error in