Reputation: 41
How i can rename default button("SET") in the DatePicker dialog?
My dialog:
case IDD_SET_NAME:
final Calendar c = Calendar.getInstance();
myYear = c.get(Calendar.YEAR);
myMonth = c.get(Calendar.MONTH);
myDay = c.get(Calendar.DAY_OF_MONTH);
DatePickerDialog DatePicker = new DatePickerDialog(this, myCallBack, myYear, myMonth, myDay);
return DatePicker;
Upvotes: 2
Views: 1341
Reputation: 132972
You can change DatePickerDialog
Set button text as:
DatePickerDialog datePicker = new DatePickerDialog(this, myCallBack, myYear, myMonth, myDay);
datePicker.setButton(DatePickerDialog.BUTTON_POSITIVE, "Enter text here", datePicker);
Upvotes: 1