Posted By

hmvrulz on 04/25/11


Tagged

button android clockLister


Versions (?)

Button with ClickLister


 / Published in: Java
 

  1. Button button_name =(Button)findViewById(R.id.ButtonId);
  2.  
  3. button_name.setOnClickListener(new View.OnClickListener() {
  4. public void onClick(View arg0) {
  5.  
  6. Intent intent_name = new Intent(Activity1.this,Activity2.class);
  7. startActivity(intent_name);
  8.  
  9. }
  10. });

Report this snippet  

You need to login to post a comment.