Add button to layout, then add the following code java file.
Button btnCalcualte=(Button) findViewById(R.id.button1);
// to enable button
btnCalcualte.setEnabled(true);
// to disable button
btnCalcualte.setEnabled(false);
Button btnCalcualte=(Button) findViewById(R.id.button1);
// to enable button
btnCalcualte.setEnabled(true);
// to disable button
btnCalcualte.setEnabled(false);
0 Comments