MaterialDesignLibrary
MaterialDesignLibrary copied to clipboard
ButtonFlat.setText("test") - cannot resolve method setText
Hi. I want to change the text in a FlatButton but Android Studio says "Cannot resolve method 'setText(java.lang.string)'".
My Code:
import com.gc.materialdesign.views.Button;
//...
Button btnRecord = (Button)findViewById(R.id.btnRecord);
btnRecord.setText("test");
How can I change the text of the button?
change it in your xml file.
I have to change the text programmatically...
import android.widget.Button;