Home > Software design >  App not working after changing Theme.MaterialComponents.DayNight.DarkActionBar to Theme.AppCompat.Li
App not working after changing Theme.MaterialComponents.DayNight.DarkActionBar to Theme.AppCompat.Li

Time:08-29

I watched a tutorial on how to create a custom Toolbar in Android Studio and I saw that I must change Theme.MaterialComponents.DayNight.DarkActionBar to Theme.AppCompat.Light.NoActionBar. I tried to do it and after running an app it showed only a splash screen and then it crashed. Please, someone, help me.

CodePudding user response:

Theme.AppCompat.Light.NoActionBar, No action bar means tool bar cant be created.

Change NoActionBar to LightActionBar or anything else you prefer. then customise the tool bar as you wish to

CodePudding user response:

Try that     

Theme.Material3.DayNight.NoActionBar

Instead of Theme.MaterialComponents.DayNight.DarkActionBar

  • Related