5

How can I fix this error. MainActivity class already in my project. Here's a screenshot of the error enter image description here

I tried this link, but it didn't work for me

Mr. Roshan
  • 1,701
  • 11
  • 33
d_a_n_u_92
  • 51
  • 1
  • 4

4 Answers4

2

I got this error as well. For me it helped to set minifyEnabled to false for my debug version. After Clean Build it launched again.

Arieck
  • 1,922
  • 2
  • 8
  • 8
2

It may be silly but make sure you have enough storage on your phone. This was the problem for me

Faraz Ahmed
  • 134
  • 10
0

I have faced this problem when I tried to build & run on real device Android 8.1, API 27. Saw this and this answers, but they didn't helped.

Solution: Then, tried to run on emulator Android 7.1 API 25, everything went fine. Hope this will help others.

Jasurbek Nabijonov
  • 1,267
  • 2
  • 20
  • 32
0

This suddenly happened to me today. After trying several other potential solutions, nothing worked. I then looked in the app configuration and noticed that the Installable Options: Deploy method had been set to "APK from app bundle" instead of "Default APK". Setting it back to "Default APK" fixed the issue for me. I hope this helps someone :-)