Skip to content

Instantly share code, notes, and snippets.

@shoomi
shoomi / DatePickerFragment
Last active July 19, 2016 13:48
Calculate the difference between two dates in two days
import android.app.DatePickerDialog;
import android.app.DialogFragment;
import android.os.Bundle;
import android.widget.EditText;
import android.widget.DatePicker;
import android.app.Dialog;
import java.util.Calendar;
public class DatePickerFragment extends DialogFragment implements DatePickerDialog.OnDateSetListener {