title: java.lang.IllegalStateException : Could not find a method onClick handler with id_button
body: <p>I want to ask about my project. I create a class (RestoranView.class) which has 3 buttons: Menu, Maps and Rating. Two of them (Maps and Rating) work well but when I clicked button "Menu", it didn't work and the logcat showed those errors. I have implemented the same code. Could you help me to fix the error? Thanks in advance.</p>
  
  <p><strong>Logcat error</strong></p>
  
  <pre><code>01-12 22:04:28.543: E/AndroidRuntime(25625): FATAL EXCEPTION: main
  01-12 22:04:28.543: E/AndroidRuntime(25625): java.lang.IllegalStateException: Could not     find a method MenuClick(View) in the activity class com.example.hellojson.RestoranView for onClick handler on view class android.widget.Button with id 'button_menu'
  01-12 22:04:28.543: E/AndroidRuntime(25625): at android.view.View$1.onClick(View.java:3685)
  01-12 22:04:28.543: E/AndroidRuntime(25625): at android.view.View.performClick(View.java:4222)
  </code></pre>
  
  <p><strong>RestoranView.java</strong></p>
  
  <pre><code>ackage com.example.hellojson;
  
  public class RestoranView extends Activity {
  
  @Override
  protected void onCreate(Bundle savedInstanceState) {
      // TODO Auto-generated method stub
      super.onCreate(savedInstanceState);
      setContentView(R.layout.restoran_view);
  
  // intent from RestoranView.class to the Map.class
  public void MenuCLick (View v) {
      Intent menu = new Intent(RestoranView.this, TabMenu.class);
      menu.putExtra(Restoran.id_restoran_tags, resto.getId_restoran());
      startActivity(menu);
  }
  
  // intent from RestoranView.class to the Map.class
  public void MapsClick(View v) {
      Intent maps = new Intent(RestoranView.this, Map.class);
      maps.putExtra(Restoran.nama_tags, resto.getNama());
      maps.putExtra(Restoran.latitude_tags, resto.getLatitude());
      maps.putExtra(Restoran.longitude_tags, resto.getLongitude());
      maps.putExtra(Restoran.desc_tags, resto.getDesc());
      startActivity(maps);
  
  }
  
  // intent from RestoranView.class to the Rating.class
  public void RatingClick(View v) {
      Intent rating = new Intent(RestoranView.this, Rating.class);
      rating.putExtra(Restoran.id_restoran_tags, resto.getId_restoran());
      rating.putExtra(Restoran.nama_tags, resto.getNama());
      startActivity(rating);
      }
  }
  </code></pre>
  
  <p><strong>RestoranView.xml</strong></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="match_parent"
      android:layout_height="match_parent"
      android:background="@drawable/background"
      android:orientation="vertical" &gt;
  
  &lt;ScrollView
      android:id="@+id/scrollView"
      android:layout_width="fill_parent"
      android:layout_height="fill_parent"
      android:fillViewport="false" &gt;
  
      &lt;LinearLayout
          android:layout_width="fill_parent"
          android:layout_height="fill_parent"
          android:orientation="vertical" &gt;
  
          &lt;TextView
              android:id="@+id/nama_restoran_view"
              android:layout_width="wrap_content"
              android:layout_height="wrap_content"
              android:layout_gravity="center_horizontal"
              android:paddingBottom="10dip"
              android:paddingTop="5dip"
              android:text="Nama Restoran"
              android:textColor="@color/Navy"
              android:textSize="25sp"
              android:textStyle="bold" /&gt;
  
          &lt;ImageView
              android:id="@+id/image_restoran_view"
              android:layout_width="275dp"
              android:layout_height="241dp"
              android:layout_gravity="center_horizontal"
              android:paddingTop="10dip"
              android:src="@drawable/ic_launcher" /&gt;
  
          &lt;TextView
              android:id="@+id/alamat_restoran_view"
              android:layout_width="wrap_content"
              android:layout_height="wrap_content"
              android:paddingTop="10dip"
              android:text="Alamat :"
              android:textColor="@color/Navy"
              android:textSize="20sp"
              android:textStyle="bold" /&gt;
  
          &lt;TextView
              android:id="@+id/phone_restoran_view"
              android:layout_width="wrap_content"
              android:layout_height="wrap_content"
              android:paddingTop="10dip"
              android:text="Phone : "
              android:textColor="@color/Navy"
              android:textSize="20sp"
              android:textStyle="bold" /&gt;
  
          &lt;TextView
              android:id="@+id/deskripsi_restoran_view"
              android:layout_width="fill_parent"
              android:layout_height="wrap_content"
              android:paddingTop="10dip"
              android:text="Deskripsi"
              android:textColor="@color/Navy"
              android:textSize="20sp"
              android:textStyle="bold" /&gt;
  
          &lt;LinearLayout
              android:layout_width="fill_parent"
              android:layout_height="wrap_content" &gt;
  
              &lt;Button
                  android:id="@+id/button_menu"
                  android:layout_width="wrap_content"
                  android:layout_height="wrap_content"
                  android:layout_weight="0.30"
                  android:onClick="MenuClick"
                  android:text="Menu" /&gt;
  
              &lt;Button
                  android:id="@+id/button_maps"
                  android:layout_width="wrap_content"
                  android:layout_height="wrap_content"
                  android:layout_weight="0.30"
                  android:onClick="MapsClick"
                  android:text="Maps" /&gt;
  
              &lt;Button
                  android:id="@+id/button_rating"
                  android:layout_width="wrap_content"
                  android:layout_height="wrap_content"
                  android:layout_weight="0.30"
                  android:onClick="RatingClick"
                  android:text="Rating" /&gt;
          &lt;/LinearLayout&gt;
      &lt;/LinearLayout&gt;
  &lt;/ScrollView&gt;
  
  &lt;/LinearLayout&gt;
  </code></pre>
  
  <p><strong>AndroidManifest</strong></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.example.hellojson"
  android:versionCode="1"
  android:versionName="1.0" &gt;
  
  &lt;uses-sdk
      android:minSdkVersion="11"
      android:targetSdkVersion="17" /&gt;
  
  &lt;uses-permission android:name="android.permission.INTERNET" /&gt;
  &lt;uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" /&gt;
  &lt;uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" /&gt;
  &lt;uses-permission android:name="com.google.android.providers.gsf.permission.READ_GSERVICES" /&gt;
  
  &lt;application
      android:allowBackup="true"
      android:icon="@drawable/ic_launcher"
      android:label="@string/app_name"
      android:theme="@style/AppTheme" &gt;
      &lt;activity
          android:name="com.example.hellojson.SplashScreen"
          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=".MenuUtama" &gt;
      &lt;/activity&gt;
      &lt;activity android:name=".AboutMedan" &gt;
      &lt;/activity&gt;
      &lt;activity android:name=".AllVenue" &gt;
      &lt;/activity&gt;
      &lt;activity android:name=".TabMenu" &gt;
      &lt;/activity&gt;
      &lt;activity android:name=".Map" &gt;
      &lt;/activity&gt;
      &lt;activity android:name=".RestoranView" &gt;
      &lt;/activity&gt;
      &lt;activity android:name=".Rating" &gt;
      &lt;/activity&gt;
      &lt;activity android:name=".Search" &gt;
      &lt;/activity&gt;
  
  
  &lt;/application&gt;
  
  &lt;/manifest&gt;
  </code></pre>