Code example for DatePickerDialog

Methods: setOnDismissListener

    public Calendar getDate() {
        return mDate;
    private DatePickerDialog constructDialog() {
        DatePickerDialog dialog = new DatePickerDialog(getContext(), this,
                mDate.get(Calendar.YEAR), mDate.get(Calendar.MONTH),
        return dialog;
    public void onClick(View v) {
        // So!  At this point, bring up the DatePickerDialog.  We'll need 
        // to listen for its completion, too, so that's ANOTHER callback... 
        mLastDialog = constructDialog();
Connect your IDE to all the code out there  Get Codota for Java