gatto
gatto

Reputation: 343

Can't find variable that used in AndroidManifest.xml for android:label

I would like to rename my application's display name (the name under the app icon on the device app list), but can't figure about where has been declared the string that used for android:label. Unfortunately I just get a project file and can't reach it's developer so I would really appreciate if somebody could help me out where should I search it. As I read in another questions it just a string, but I can't find it in the AndroidManifest.xml

android:icon="@mipmap/ic_launcher"
        android:label="@string/app_name"
        android:theme="@style/AppTheme" >
        <activity
            android:name=".SplashScreenActivity"
            android:label="@string/app_name"

Upvotes: 0

Views: 309

Answers (2)

Andrew Brooke
Andrew Brooke

Reputation: 12153

That is a string that has been created in your project's strings.xml file, located in res/values/strings.xml (the name of the actual file is arbitrary, but it is strings.xml by default)

Here is the official documentation on String resources: http://developer.android.com/intl/es/guide/topics/resources/string-resource.html

Since you are referencing it in xml, you use @string/app_name, and it will automatically find the string called app_name from your resources

Upvotes: 3

Kavan
Kavan

Reputation: 340

The string can be found in the strings.xml file, which is located inside the res/values directory.

Upvotes: 1

Related Questions