Code example for DatePicker

Methods: clearFocusgetDayOfMonthgetMonthgetYear

0
	 
	 
	private OnClickListener mOkListener = new OnClickListener() {
		public void onClick(View arg0) { 
			//These force values from internal edit fields being parsed. 
			_datePicker.clearFocus(); 
			_timePicker.clearFocus(); 
			 
			_init.set(Calendar.YEAR, _datePicker.getYear()); 
			_init.set(Calendar.MONTH, _datePicker.getMonth()); 
			_init.set(Calendar.DAY_OF_MONTH, _datePicker.getDayOfMonth()); 
			 
			_init.set(Calendar.HOUR_OF_DAY, _timePicker.getCurrentHour()); 
			_init.set(Calendar.MINUTE, _timePicker.getCurrentMinute()); 
			_init.set(Calendar.SECOND, 0); 
			_init.set(Calendar.MILLISECOND, 0); 
			sendResult(_callback, _init, _opaque); 
		} 
	}; 
	 
	private OnClickListener mCancelListener = new OnClickListener() {