title: Android, second activity does not launch
body: <p>I have a basic Android app set up with two activities. The problem is that the first one opens, and just stays there forever, and the second one does not launch.</p>
  
  <p>Could anyone say what's wrong?</p>
  
  <p>MainActivity.java</p>
  
  <pre><code>package com.desecrationstudios.firstapp;
  
  import android.app.Activity;
  import android.os.Bundle;
  import android.view.Menu;
  import android.view.View;
  import android.widget.Button;
  import android.widget.TextView;
  
  public class MainActivity extends Activity {
  
  int counter;
  Button add, sub;
  TextView display;
  
  @Override
  protected void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
      setContentView(R.layout.linear);
      counter = 0;
      add = (Button) findViewById(R.id.bAdd);
      sub = (Button) findViewById(R.id.bSub);
      display = (TextView) findViewById(R.id.tvDisplay);
  
      add.setOnClickListener(new View.OnClickListener(){
  
          public void onClick(View v){
              counter++;
              display.setText("Your total is " + counter);
          }
      });
  
      sub.setOnClickListener(new View.OnClickListener(){
  
          public void onClick(View v){
              counter--;
              display.setText("Your total is " + counter);
          }
      });
  }
  
  @Override
  public boolean onCreateOptionsMenu(Menu menu) {
      // Inflate the menu; this adds items to the action bar if it is present.
      getMenuInflater().inflate(R.menu.main, menu);
      return true;
  }
  
  }
  </code></pre>
  
  <p>Splash.java:</p>
  
  <pre><code>package com.desecrationstudios.firstapp;
  
  import android.app.Activity;
  import android.os.Bundle;
  
  public class Splash extends Activity{
  
  @Override
  protected void onCreate(Bundle splash) {
      super.onCreate(splash);
      setContentView(R.layout.splash);
  }
  
  }
  </code></pre>
  
  <p>AndroidManifest.xml</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;manifest xmlns:android="http://schemas.android.com/apk/res/android"
  package="com.desecrationstudios.firstapp"
  android:versionCode="1"
  android:versionName="1.0" &gt;
  
  &lt;uses-sdk
      android:minSdkVersion="8"
      android:targetSdkVersion="17" /&gt;
  
  &lt;application
      android:allowBackup="true"
      android:icon="@drawable/icon"
      android:label="@string/app_name"
      android:theme="@style/AppTheme" &gt;
      &lt;activity
          android:name=".Splash"
          android:label="@string/app_name" &gt;
          &lt;intent-filter&gt;
              &lt;action android:name="android.intent.action.MAIN" /&gt;
  
              &lt;category android:name="android.intent.category.LAUNCHER" /&gt;
          &lt;/intent-filter&gt;
      &lt;/activity&gt;
  
      &lt;activity
          android:name=".MainActivity"
          android:label="@string/app_name" &gt;
      &lt;/activity&gt;
  
  &lt;/application&gt;
  
  &lt;/manifest&gt;
  </code></pre>
  
  <p>Thanks!</p>