title: Force close error on setOnClickListener (Example from hello Android book section 3.5)
body: <p>I am having problem in starting a new activity on clicking a button, here's my code:</p>
  
  <pre><code>package test.project;
  
  import android.app.Activity;
  import android.os.Bundle;
  import android.content.Intent;
  import android.view.View;
  import android.view.View.OnClickListener;
  
  public class TestActivity extends Activity implements OnClickListener {
      /** Called when the activity is first created. */
      @Override
      public void onCreate(Bundle savedInstanceState) {
          super.onCreate(savedInstanceState);
          setContentView(R.layout.main);
  
    View aboutButton = findViewById(R.id.about_content);
          aboutButton.setOnClickListener(this);
      }
  public void onClick(View v) {
          switch (v.getId()) {
          case R.id.about_content:
          Intent i = new Intent(this, testit.class);
          startActivity(i);
          break;
          // More buttons go here (if any) ...
          }
      }
  }
  </code></pre>
  
  <p>Can anyone please help me correct this error</p>
  
  <p>Error Line</p>
  
  <pre><code>aboutButton.setOnClickListener(this);
  </code></pre>
  
  <p>Main.xml file</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
      android:layout_width="fill_parent"
      android:layout_height="fill_parent"
      android:orientation="vertical" &gt;
  
      &lt;TextView
          android:layout_width="fill_parent"
          android:layout_height="wrap_content"
          android:text="@string/hello" /&gt;
  
      &lt;Button
          android:id="@+id/button1"
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:text="Click here" android:layout_gravity="center"
  android:text="Click here" android:layout_gravity="center" android:layout_marginTop="30dip"/&gt;
  &lt;/LinearLayout&gt;
  </code></pre>
  
  <p>XML file containing about_content is</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  
  &lt;ScrollView
      xmlns:android="http://schemas.android.com/apk/res/android"
      android:layout_width="fill_parent"
      android:layout_height="fill_parent"
      android:padding="10dip" &gt;
      &lt;TextView
          android:id="@+id/about_content"
          android:layout_width="wrap_content"
          android:layout_height="wrap_content"
          android:text="@string/about_text" /&gt;
  &lt;/ScrollView&gt;
  </code></pre>
  
  <p>about_content is already defined here</p>
  
  <pre><code>&lt;TextView
              android:id="@+id/about_content"
              android:layout_width="wrap_content"
              android:layout_height="wrap_content"
              android:text="@string/about_text" /&gt;
  </code></pre>