Questions tagged [android-studio-3.0]

Use for questions about using Android Studio, an official IDE targeted at Android development. Do NOT use for questions about programming for Android in general; instead use [android].

Android Studio is the official IDE for Android development, and includes everything you need to build Android apps.

For more updates about Android Studio 3.0 check out these videos

  1. AS 3.0
  2. Java 8 support
  3. The new Profiler
1629 questions
12
votes
4 answers

Crash when using custom font for Toolbar

In my activity, I have a custom toolbar. I'm trying to change its title font. Previously, I was able to do that by putting the font in the asset folder. With Android Studio 3, we can now use fontFamily and FontsContract. I tried this approach…
usernotnull
  • 3,480
  • 4
  • 25
  • 40
12
votes
1 answer

Error:(72) unknown element found

I am using Dji-SDK. Recently i migrated the SDK from version 4.2 to 4.3.2. After changing the dji-sdk.aar in the libs folder i am not able to build because of the merge issues in the manifest. The merged manifest in build is getting created as…
jknair0
  • 1,194
  • 13
  • 24
12
votes
3 answers

Lint: "Newer Library Versions Available" when using variables

I have a project with 3 sub-projects. I want the 3 sub-projects to use the same dependencies versions so I factored all the versions in the root build.gradle: allprojects { ext.versions = [ supportLibVersion: '26.1.0', …
mbonnin
  • 6,893
  • 3
  • 39
  • 55
12
votes
3 answers

Android studio 3.0 Canary NPE after update

I'm updated Android Studio Canary from 2 to 3 (current version), and now I'm getting error when building project: 2017-06-15 16:32:00,831 [ thread 12] INFO - e.project.sync.GradleSyncState - Gradle sync failed: Cause:…
11
votes
5 answers

Android Studio 3.1 does not render an XML file due to a Java class missing

It always shows me this error in the massages: java.lang.ClassNotFoundException: android.view.View$OnUnhandledKeyEventListener My project is literally Hello, World! and I just open Android Studio and click on the empty activity and then wait for…
Parsa Mahmoodi
  • 139
  • 1
  • 1
  • 7
11
votes
3 answers

How to Setup Jetpack Navigation with material.BottomNavigationView

I am unable to setup Navigation component with com.google.android.material.bottomnavigation.BottomNavigationView it is giving an error. Here is the code that I am trying to use // Setup bottom navigation view …
Pedro Massango
  • 4,114
  • 2
  • 28
  • 48
11
votes
2 answers

Multiple dex files define Lcom/google/android/gms/internal/measurement/zzabn

Since this morning I cannot build my Android app because I get this error What went wrong: Execution failed for task ':app:transformDexArchiveWithDexMergerForDebug'. com.android.build.api.transform.TransformException:…
Alexis
  • 1,825
  • 4
  • 23
  • 28
11
votes
3 answers

Timeout Error when connecting localhost api with Android Studio on Real devices through USB

I am using Android Studio version 3 on Window 8.1. There is XAMPP installed to host php api on localhost. I am trying to access the localhost api from Android Studio. In the host name, I used IPv4 Address. When I access it from Android Version 3,…
Pankaj
  • 9,749
  • 32
  • 139
  • 283
11
votes
3 answers

How to set click listener to LinearLayout using data binding

I am currently trying to set a click listener to a LinearLayout view in the .xml layout file using data binding. I have managed to get it to work well on other views like a Button or TextView, but for some reason it is not working with a…
Shadow
  • 4,168
  • 5
  • 41
  • 72
11
votes
0 answers

How to show logcat header on every line?

I just updated Android Studio to the last stable version 3.1 I noticed that something has changed in the logcat tab: in the previous release every line of the logcat started with the header; now the header is printed only at the start of "every…
appersiano
  • 2,670
  • 22
  • 42
11
votes
3 answers

Android Studio stuck patching a system image

I just clicked the update button on Android Studio. It downloaded packages and it got stuck at the point shown in the image.
Merhawi Fissehaye
  • 2,482
  • 2
  • 25
  • 39
11
votes
1 answer

How to treat memory leaks using the new AndroidProfiler

I'm trying to learn how to identify and treat memory leaks in my App. I'm reading this great article, but I'm a bit confused about how to apply that in the new "Android Profiler" tool, that came with Android Studio 3.0. I'have a test application and…
11
votes
4 answers

Use XML attribute paddingHorizontal on pre API 26 devies?

Is the XML attribute android:paddingHorizontal that was introduced in API 26 (Android O) only available in 26 and above? Is there a support version of it? I require my minSdkVersion to be much lower than 26. I’m under the impression that the Android…
Sakiboy
  • 7,252
  • 7
  • 52
  • 69
11
votes
4 answers

Using a prebuilt shared Library in Android Studio (cmake)

I want to use a C++ shared library inside my Android App. I tried to follow along the hello-libs example from Google's NDK samples, but somehow it doesn't work out. It seems, that my library isn't packed into the APK. All tutorials i found are using…