button sound when pressed
<p>I cant seem to find were i am going wrong what i want is to press the image button and to go to my second activity and also on clicking the button it makes a sound. any help would be great </p>

<pre><code>package my.solo;

import android.app.Activity;
import android.content.Intent;
import android.media.MediaPlayer;
import android.os.Bundle;
import android.text.method.ScrollingMovementMethod;
import android.view.View;
import android.widget.Button;
import android.widget.TextView;

public class SoloActivity extends Activity {
    /** Called when the activity is first created. */
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.main);

        final MediaPlayer mpButtonClick = 
                MediaPlayer.create(this,R.raw.button_click);

        TextView textView = (TextView)findViewById(R.id.text_view);
        textView.setMovementMethod(new ScrollingMovementMethod()); 

        Button next = (Button) findViewById(R.id.imageButton1);
        next.setOnClickListener(new View.OnClickListener() {
            public void onClick(View view) {
                Intent intent = new Intent(SoloActivity.this
                        , model_page.class);
                startActivity(intent);

                mpButtonClick.start();
            }
        }
    )
}
</code></pre>

<p>xml</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:background="@drawable/pt5"
    android:orientation="vertical" &gt;
    &lt;RelativeLayout android:id="@+id/relativeLayout1"
        android:layout_width="match_parent"
        android:layout_height="fill_parent" &gt;
        &lt;TextView android:id="@+id/text_view"
            android:layout_width="415dp"
            android:layout_height="209dp"
            android:layout_marginLeft="300dp"
            android:layout_marginTop="50dp"
            android:maxLines="300"
            android:scrollbars="vertical"
            android:singleLine="false"
            android:text="@string/disclamer"
            android:textColor="@android:color/secondary_text_dark_nodisable"/&gt;
        &lt;ImageButton android:id="@+id/imageButton1"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_alignParentBottom="true"
            android:layout_centerHorizontal="true"
            android:layout_marginBottom="98dp"
            android:src="@drawable/stbtn2" 
            android:background="@null"/&gt;
        &lt;TextView android:id="@+id/textView1"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_alignParentBottom="true"
            android:layout_centerHorizontal="true"
            android:layout_marginBottom="35dp"
            android:text="@string/P69"
            android:textSize="25dp"
            android:textStyle="bold"
            android:typeface="serif"/&gt;
    &lt;/RelativeLayout&gt;
&lt;/LinearLayout&gt;
</code></pre>

<p>i have put the second activity in the MF so thats ok </p>

<p><a href="http://imageshack.us/g/638/bugjd.png/" rel="nofollow">http://imageshack.us/g/638/bugjd.png/</a></p>
