Search code examples
androidxmlandroid-actionbartitlebar

How to remove title bar in android?


I want to do android program that contains no title bar. For some reason I cant remove title bar. I have already tried this coding.

this.requestWindowFeature(Window.FEATURE_NO_TITLE);

This one also I have tried but the program suddenly stops..

 android:icon="@drawable/icon" 
 android:label="@string/app_name" 
 android:theme="@android:style/Theme.NoTitleBar.Fullscreen"

How can I fix this?


Solution

  • In the Style.xml window (App->src->main->res->values->styles.xml) make changes to the <resources> to look like this:

    <resources>
    
        <style name="AppTheme" parent="Theme.AppCompat.NoActionBar">
    
        </style>
    
    </resources>