title: find month and days difference from two date
body: <p>I want to find the date difference in month and days between two dates. One is my system current date and another is in the future.</p>
  <p>and the future date is in this format:</p>
  <blockquote>
  <p>2014-02-06 21:26</p>
  </blockquote>
  <p>I have used below code to find the difference.</p>
  <p>1.</p>
  <pre><code>currentCal = Calendar.getInstance();
  weddingCal = Calendar.getInstance();
  weddingCal.clear();
  DateFormat formatterResponseDate = new SimpleDateFormat(&quot;yyyy-MM-dd HH:mm&quot;);
  formatterResponseDate.setTimeZone(TimeZone.getTimeZone(&quot;GMT&quot;)); 
  weddingCal.setTime(formatterResponseDate.parse(responseThis.trim()));
  long dateDiff = weddingCal.getTimeInMillis() -
  currentCal.getTimeInMillis();
  long months = dateDiff / (30 * 24 * 60 * 60 * 1000); 
  long days = (dateDiff % (30 * 24 * 60 * 60 * 1000)) / (24 * 60 * 60 * 1000);
  </code></pre>
  <p>But it gives me wrong result and I think it's not convenient because sometimes there are 31 days in a month. I have also used <a href="http://joda-time.sourceforge.net/api-release/index.html" rel="nofollow noreferrer">JODA - Time</a> to find the difference, but it also does not help me.</p>
  <p>2.</p>
  <pre><code>currentCal = Calendar.getInstance();
  startDate = new DateTime(currentCal.get(Calendar.YEAR),
  (currentCal.get(Calendar.MONTH)+1),
  currentCal.get(Calendar.DAY_OF_MONTH), currentCal.get(Calendar.HOUR),
  currentCal.get(Calendar.MINUTE));
  weddingCal = Calendar.getInstance();
  weddingCal.clear();
  weddingCal.setTime(formatterResponseDate.parse(responseThis.trim()));
  endDate = new DateTime(weddingCal.get(Calendar.YEAR), (weddingCal.get(Calendar.MONTH)+1),
  weddingCal.get(Calendar.DAY_OF_MONTH), weddingCal.get(Calendar.HOUR),
  weddingCal.get(Calendar.MINUTE));
  Period period = new Period(startDate, endDate);
  tvMonth.setText(String.valueOf(period.getMonths()));
  tvDays.setText(String.valueOf(period.getDays()));
  </code></pre>
  <p>Both are not working please help me, how Can I find it?
  Thanks</p>