I am doing an android project using Android Studio. My project name is "Policia". I run the project on emulator and it shows another name "LoginActivity". Actually its the launcher activity. How can I solve this??
android project name and app name are different
1.1k Views Asked by Nisfan At
2
There are 2 best solutions below
0

This is happening because you tried to change the label of your launcher activity (activity that is started when the user starts your app) from the string/app_name
attribute in the manifest file to something else.
To change the label(title) of your activity without any strange behaviour, go to your activity and add the label there. In the onCreate()
method, do this:
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setTitle(R.string.your_app_title); //<--change title to whatever you want
setContentView(R.layout.activity_main);
}
In your main activity listed in manifest file see the
android:label
valueThen see
string.xml
file in resource (res
) folder to see the actual String value ofapp_name
. Change it to whatever you desire.Main activity will be the one with following intent-filter