Hi,
I have 2 dates
based upon that i am calculating difference
currently my requirement is that based upon that i am going to round of the value
my expeted o/ps
1)3.1234-3.12
2)3.45699-3.46
could you please help me
public JsonResult GetNoOfMonths(string psd, string ped)
{
DateTime dtPSD = Convert.ToDateTime(psd);
DateTime dtPED = Convert.ToDateTime(ped);
int days = (dtPED - dtPSD).Days;
double month = (days + 1) / 30.0;
double d = Math.Floor(month * 100) / 100;
return Json(d, JsonRequestBehavior.AllowGet);
}