how to change textAlhgin for textview in android studio' code example
Example 1: android studio textbox change text
XML:
Java:
TextView msg = findViewById(R.id.helloTxt);
msg.setText("Hello");
Example 2: set text in edittext android
EditText editText = (EditText)findViewById(R.id.edit_text);
editText.setText("This sets the text.", TextView.BufferType.EDITABLE);