Launch Another App From My App Android
<p>I'm simply trying to launch one of my apps from within another app. I have this code:</p>

<pre><code>Intent intent = new Intent(Intent.ACTION_MAIN);
intent.setComponent(new ComponentName("com.my.app","com.my.app.Main"));
startActivity(intent);
</code></pre>

<p>But it keeps giving me this error:</p>

<pre><code>Unable to find explicit activity class {com.my.app/com.my.app.Main}; have you declared this activity in your AndroidManifest.xml?
</code></pre>

<p>Which manifest is it referring to? The second app that I'm trying to launch, or the app from which I'm trying to launch it? Also, what am I supposed to be declaring exactly?</p>

<p>If you need more information, please let me know. It's probably something simple but I've looked through all the related questions / answers on SO and none of the solutions worked for me.</p>

<p>Thanks!</p>