String birth = "1993-03-06"; // set date
SimpleDateFormat s = new SimpeDateFormat ( "yyyy-MM-dd"); // set format
Date b = s.parse (birth); // create objects date
long btime = b.getTime (); // ms Switch
long now = new Date () getTime;. // Get the current date into milliseconds
long days = (now-btime) / 1000/60/60/24; // calculate the number of days into milliseconds.
Calendar:
Calendar c=new Calendar()
The number of milliseconds to create calenday object:
long ctime=c.getTime().getTime();