[Android Q&A, Help & Troubleshooting] gamerz36:
Hi, every project I try to launch on my phone triggers the same error

-Error happens even on first install of the app on the phone..

-Error happens with any project at any point

-Yes, I tried to Clean, Rebuild, Invalidate and Restart and also manually delete the app on the phone

-Yes I tried adb kill and start

I think the error might be related to the phone and not my code as it's a sample blank code.

Any clue? Cant get to run anything at all....

Error

04/17 15:18:59: Launching app
$ adb shell am start -n "com.example.hellonothing/com.example.hellonothing.MainActivity" -a android.intent.action.MAIN -c android.intent.category.LAUNCHER
Error while executing: am start -n "com.example.hellonothing/com.example.hellonothing.MainActivity" -a android.intent.action.MAIN -c android.intent.category.LAUNCHER
Starting: Intent { act=android.intent.action.MAIN cat=[android.intent.category.LAUNCHER] cmp=com.example.hellonothing/.MainActivity }
Error type 3
Error: Activity class {com.example.hellonothing/com.example.hellonothing.MainActivity} does not exist.

Error while Launching activity

Android Manifest

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android=""
package="com.example.hellonothing">

<application
android:allowBackup="true"
android:icon="[USER=22138]@Mipmap[/USER]/ic_launcher"
android:label="[USER=696546]@String[/USER]/app_name"
android:roundIcon="[USER=22138]@Mipmap[/USER]/ic_launcher_round"
android:supportsRtl="true"
android:theme="[USER=19691]@Style[/USER]/AppTheme">
<activity
android:name=".MainActivity"
android:label="[USER=696546]@String[/USER]/app_name"
android:theme="[USER=19691]@Style[/USER]/AppTheme.NoActionBar">
<intent-filter>
<action android:name="android.intent.action.MAIN" />

<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>

</manifest>

Main Activity Code

package com.example.hellonothing;

import android.os.Bundle;
import android.support.design.widget.FloatingActionButton;
import android.support.design.widget.Snackbar;
import android.support.v7.app.AppCompatActivity;
import android.support.v7.widget.Toolbar;
import android.view.View;
import android.view.Menu;
import android.view.MenuItem;

public class MainActivity extends AppCompatActivity {

[USER=1021285]@override[/USER]
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
Toolbar toolbar = findViewById(R.id.toolbar);
setSupportActionBar(toolbar);

FloatingActionButton fab = findViewById(R.id.fab);
fab.setOnClickListener(new View.OnClickListener() {
[USER=1021285]@override[/USER]
public void onClick(View view) {
Snackbar.make(view, "Replace with your own action", Snackbar.LENGTH_LONG)
.setAction("Action", null).show();
}
});
}

[USER=1021285]@override[/USER]
public boolean onCreateOptionsMenu(Menu menu) {
// Inflate the menu; this adds items to the action bar if it is present.
getMenuInflater().inflate(R.menu.menu_main, menu);
return true;
}

[USER=1021285]@override[/USER]
public boolean onOptionsItemSelected(MenuItem item) {
// Handle action bar item clicks here. The action bar will
// automatically handle clicks on the Home/Up button, so long
// as you specify a parent activity in AndroidManifest.xml.
int id = item.getItemId();

//noinspection SimplifiableIfStatement
if (id == R.id.action_settings) {
return true;
}

return super.onOptionsItemSelected(item);
}
}

Thank you !