CS Electrical And Electronics
@cselectricalandelectronics

How to remove actionbar in android studio?

All QuestionsCategory: Mobile Apps, Android Studio, IOS, FlutterHow to remove actionbar in android studio?
chetan shidling asked 4 years ago

I need small information.

1 Answers
chetan shidling answered 4 years ago

First go to res folder, then values folder, and then you will find styles.xml file.
 
The code will be:
 

<resources>

<!-- Base application theme. -->
<style name="AppTheme" parent="Theme.AppCompat.Light.DarckActionBar">
<!-- Customize your theme here. -->
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorAccent">@color/colorAccent</item>
</style>

</resources>


Instead of DarkActionBar replace it with NoActionBar. Like this.

<resources>

<!-- Base application theme. -->
<style name="AppTheme" parent="Theme.AppCompat.Light.NoActionBar">
<!-- Customize your theme here. -->
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorAccent">@color/colorAccent</item>
</style>

</resources>