Button myButton = (Button) findViewById(R.id. my_button
As much I know in java all code have to be on a class body, that said if we invoke a method