AndroidMultiCalendarTools
AndroidMultiCalendarTools copied to clipboard
android date tools and date picker for tree calendar "Jalali" and "Hijri" and "Gregorian"
Android multi calender tools library for android
android date tools and date picker for tree calendar systems Jalali , Hijri , Gregorian
Screen shots
primary color will be your theme color
Add to your project
copy this to "yourProject/app/libs"
have problem?
How to use
date converter: more here.
DateModel hijri = DateConverter.GregorianToHijri(2018, 1, 1);
//hijri.day;
//hijri.month;
//hijri.year;
date picker:
xml:(don't change height and width)
<com.ali.uneversaldatetools.datePicker.UDatePicker
android:id="@+id/date_picker"
android:layout_width="300dp"
android:layout_height="350dp"/>
java:
UDatePicker uDatePicker = findViewById(R.id.date_picker);
//push date to show in first time
uDatePicker.ShowDatePicker(dateSystem);
//or use current date
uDatePicker.ShowDatePicker(Calendar.Jalali);
//get on day selected event
uDatePicker.setOnDateSelected((dateSystem, unixTime) -> {
//do something...
});
//or get date when ever you want
uDatePicker.getSelectedUnixTime();//as a unix time
uDatePicker.getSelectedDate();//as a DateSystem object
Supported language:
1.persian
2.english
and its easy to add new language see
here.
LICENCE
under MIT licence