Skip to content

Commit f7d95b4

Browse files
committed
Added example for setting date range in sample.
1 parent ce0465d commit f7d95b4

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

datetimepicker-sample/src/com/fourmob/datetimepicker/sample/MainActivity.java

+4
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,10 @@ protected void onCreate(Bundle savedInstanceState) {
3636
public void onClick(View v) {
3737
datePickerDialog.setVibrate(isVibrate());
3838
datePickerDialog.setYearRange(1985, 2028);
39+
40+
// Alternatively, you can set the date range of the Date Picker
41+
// datePickerDialog.setDateRange(startYear, startMonth, startDay, endYear, endMonth, endDay);
42+
3943
datePickerDialog.show(getSupportFragmentManager(), DATEPICKER_TAG);
4044
}
4145
});

0 commit comments

Comments
 (0)