on 05-07-2010 3:40 PM
Rqrmt: to show the number of years, months and days between two dates.
Date1: 01/01/2005
Date2: 02/02/2010
Result to show: 1D;1M;5Y or whatever format?
Using variables within functions rolls each in total, but the days are showing all days, all months, not just "each part"
Hi,
You can display them as:
Total Days = Daysbetween(02/02/2010;01/01/2005)
Years = Total Days/365
Months =(Total Days - Years*365)/30
Days = Total Days - years365 - months30
Now you can combine them in 1 single variable using concat:
Final = Days"D"Months"M"Years+"Y"
Regards,
Rohit
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
93 | |
10 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.