Buttonbutton=(Button)findViewById(R.id.button_send);button.setOnClickListener(newView.OnClickListener(){publicvoidonClick(Viewv){// Do something in response to button click}});
ImageView
Images files are referred to as drawables. They are put in folders for each device resolution inside the res directory, e.g. res/drawable-xxhdpi. The runtime chooses which image to use on each device. @drawable/my_image refers to the image my_image.png located in all the drawable folders you are providing.