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

One of those types of annoying errors that'll have you do a lot of work for something that's actually a 2 second job and no real effort.

If you find yourself with an app that crashes with no output, open logcat from visual studio and you'll notice that around the time of our app crash, there's a lot that states 'You need to use a Theme.AppCompat theme (or descendant) with this activity'. At first you'll start to look into the application and where you might change the theme, but in reality, if we go down that route, it could end up changing your entire app look and feel, something which will take a long time to put back to normal.

It turns out that the fix for this issue is actually to clean the Android solution and run again as normal, this will solve the crash and your error will disappear from logcat.

If you run into any issues after cleaning and running where this error is still present, comment below.

My particular setup when I got this error was as follows:

Minimum Android Version: 4.2 (API 17 - Jelly Bean)

Target Android Version: 7.0 (API 24 - Nougat)


Published at

Tags: Android,Xamarin

Luke Alderton

Comments

JM
Thanks Bro, this helped. Glad you posted this because I was stranded.
10/10/2018
Share with
Tags
Latest Comments
By Mark Gentry on Windows Server 2019 - Change product key does nothing
20 Aug 2021, 03:30 AM
By Cathy on In-Place Upgrade for a Windows Server domain controller
31 Jul 2021, 18:28 PM
By Mr. Greymatter on Raspberry Pi - Running Java app on Raspbian
16 Feb 2021, 07:35 AM
By Mikko Seittenranta on Xamarin Forms multiple instances of same app open
16 Feb 2021, 04:34 AM
By Andrew on Auto/Custom height on Xamarin Forms WebView for Android and iOS
22 Jan 2021, 22:15 PM
By Nick on Raspberry Pi - Running Java app on Raspbian
14 Oct 2020, 19:37 PM
By Ivan on Fixed: Value cannot be null Parameter Name: source
15 Sep 2020, 19:47 PM
By Anand on Raspberry Pi - Bluetooth using Bluecove on Raspbian
7 Sep 2020, 16:53 PM
Categories
App Development
Event
Game Development
Mapping
Modelling
Programming
Review
Robotics
Tutorial
Web Development