FernandoPaiva
FernandoPaiva

Reputation: 4460

How do I to change the Android Theme of a Xamarin project?

I'm trying to change the Android's theme of a Xamarin project. To do this I'm changing the AndroidManifest.xml adding the clausule <application android:theme="@android:style/Theme.DeviceDefault.Light" android:label="MyApp.Android"></application> and erasing the Theme = "@style/MainTheme" in MainActivity.cs but it just crash and doesn't open the App.

How could I do this ?

Upvotes: 0

Views: 260

Answers (1)

Cherry Bu - MSFT
Cherry Bu - MSFT

Reputation: 10346

Change the Java inheritance from AppCompatActivity to Activity, then you will solve this issue.

Please take a look the following thread for detailed info:

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

Upvotes: 1

Related Questions