How to calculate days in years and months in c#? per example :
If
1. days = 385
then I need to display Year= 1.1
(i.e. 1 year 1 month)
2. days= 234
then I need to display year =0.7
(i.e 0 year 7 months)
How can we calculate in c#?
I did for days=234 /365
and result is coming 0.64 (i.e. 0 year 6 months). But actually it is 7 months.
How to get accurate year and months.