AvMishra
AvMishra

Reputation: 1415

How to change the application name in android

In my project when application is get installed it naming the app name as {@string/welcome_msg} not {@string/app_name}. Is there any way to make the application name not same as Main Activity label?

Below is my manifest code:-

<application android:theme="@style/AppTheme" android:icon="@drawable/icon" android:label="@string/app_name">
        <activity android:name=".StartActivity" android:label="@string/welcome_msg">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>
        <activity android:name=".LoginActivity" android:label="@string/login">
            <intent-filter>
                <action android:name="com.gymup.project.LOGINACTIVITY" />
                <category android:name="android.intent.category.DEFAULT" />
            </intent-filter>
        </activity>
</application>

Upvotes: 1

Views: 2174

Answers (2)

Ian
Ian

Reputation: 3520

You're avoiding the real question here:

How to get ride of title bar?

Answer:

In activity entry of manifest: android:theme="@android:style/Theme.NoTitleBar"

Upvotes: 0

Joe Simpson
Joe Simpson

Reputation: 2594

Change the label in your manifest to the app's name, then in your code use

this.setTitle( R.string.lable );

on onCreate(..)

Upvotes: 2

Related Questions