Thursday, 17 January 2013

Hide Status Bar / Title Bar in Android Activity

How to hide the title bar for an Activity in XML with existing custom theme

 If you want to hide the title bar from android activity then use following code in oncreate method of activity.


@Override
protected void onCreate(Bundle savedInstanceState) {
 super.onCreate(savedInstanceState);
 requestWindowFeature(Window.FEATURE_NO_TITLE);
 this.getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN,
 WindowManager.LayoutParams.FLAG_FULLSCREEN);

 setContentView(R.layout.temp);
 
 
NovaRadix Android Application Development Team
NovaRadix Technology
WWW.NOVARADIX.COM

2 comments:

  1. getWindow().getDecorView().setSystemUiVisibility(View.GONE);

    Try this,It will work

    ReplyDelete
  2. I simply want to say I’m very new to blogs and actually loved you’re blog site. Almost certainly I’m going to bookmark your blog post . You absolutely come with great well written articles. Thanks a lot for sharing your blog.

    Android Training institute in chennai with placement | Android Training in chennai |Best Android Training in Velachery | android development course fees in chennai

    ReplyDelete

Call web services easily

get source code from here, Download