[Solved] Starting activity with button


 import android.app.Activity;
 import android.content.Intent;
 import android.os.Bundle;
 import android.view.View;
 import android.widget.ImageView;
 import android.widget.Toast;

     public class Contact extends Activity
       {

public ImageView btnlog1;

    @Override
protected void onCreate(Bundle savedInstanceState) 
{
    super.onCreate(savedInstanceState);
    setContentView(R.layout.activity_main);

    btnlog1=(ImageView)findViewById(R.id.imageView2);
            btnlog1.setOnClickListener(new View.OnClickListener() {

        @Override
        public void onClick(View v) {
            // TODO Auto-generated method stub
            Intent l = new Intent(Contact.this,                  
                       AndroidDashboardDesignActivity.class);
            startActivity(l);
            Contact.this.finish();
        }
    });



 }



      }

Use this code and try like this.. This is simple code for intent changing for one activity to another.. let me know your ans..

solved Starting activity with button