java.lang.IllegalStateException: You need to use a Theme.AppCompat theme (or descendant) with this activity.

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Solutions on the web

via Stack Overflow by Roman Fedoruk
, 1 year ago
You need to use a Theme.AppCompat theme (or descendant) with this activity.
via Stack Overflow by Unknown author, 2 years ago
You need to use a Theme.AppCompat theme (or descendant) with this activity.
via Stack Overflow by Gregg
, 1 month ago
You need to use a Theme.AppCompat theme (or descendant) with this activity.
via GitHub by ranbeuer
, 6 months ago
You need to use a Theme.AppCompat theme (or descendant) with this activity.
via GitHub by xuefer
, 10 months ago
You need to use a Theme.AppCompat theme (or descendant) with this activity.
via Stack Overflow by Drille Doge
, 1 year ago
This Activity already has an action bar supplied by the window decor. Do not request Window.FEATURE_SUPPORT_ACTION_BAR and set windowActionBar to false in your theme to use a Toolbar instead.
java.lang.IllegalStateException: You need to use a Theme.AppCompat theme (or descendant) with this activity.
at android.support.v7.app.AppCompatDelegateImplV7.createSubDecor(AppCompatDelegateImplV7.java:340)
at android.support.v7.app.AppCompatDelegateImplV7.ensureSubDecor(AppCompatDelegateImplV7.java:309)
at android.support.v7.app.AppCompatDelegateImplV7.setContentView(AppCompatDelegateImplV7.java:273)
at com.example.roman.realestatecalculator.MainActivity.onCreate(MainActivity.java:32)
at android.app.Activity.performCreate(Activity.java:6876)
at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1135)

Users with the same issue

Once, 1 year ago
2 times, 1 year ago
Once, 5 months ago
Once, 8 months ago
3 times, 9 months ago
10 more bugmates

Know the solutions? Share your knowledge to help other developers to debug faster.