Closed zoro238 closed 5 years ago
Get text on selected button in SingleSelectToggleGroup
:
SingleSelectToggleGroup single = findViewById(R.id.group_choices);
int checkedId = single.getCheckedId();
CircularToggle toggle = single.findViewById(checkedId);
Log.v(LOG_TAG, "Selected text: " + toggle.getText());
Get text on selected button in MultiSelectToggleGroup
:
MultiSelectToggleGroup multi = findViewById(R.id.group_weekdays);
for (int checkedId : multi.getCheckedIds()) {
CircularToggle toggle = multi.findViewById(checkedId);
Log.v(LOG_TAG, "Selected text: " + toggle.getText());
}
thank you a lots my brother
In a file xml I put text for each one single so how does the contents of the text in the selected file give me the programmatically