Date Calculator

Jayliam

New Member
Joined
May 12, 2015
Messages
31
Office Version
  1. 365
Platform
  1. Windows
  2. Mobile
I'm having trouble getting this basic formula to work.

Current formula: =DATEDIF(F12,TODAY(),"ym")&"Months, "&F12-DATE(YEAR(F12),MONTH(F12),1)&"Days"

F12 = 11/8/2024. Should be 3 days but it says 7. Anyone know what I've done wrong?
 

Excel Facts

Best way to learn Power Query?
Read M is for (Data) Monkey book by Ken Puls and Miguel Escobar. It is the complete guide to Power Query.
For the days, you are subtracting the first day of the month from the date in F12 (8-1), which returns 7.
I think you want to subtract the the date in cell F12 from the current date (TODAY()), i.e.
Excel Formula:
=DATEDIF(F12,TODAY(),"ym")&"Months, "&(TODAY()-F12)&"Days"
 
Upvote 0
Thank you. That definitly got me loser. Is there anyway I can have it only show the days remaining and not the total days?

Current formula: =DATEDIF(F11,TODAY(),"ym")&" Months, "&(TODAY()-F11)&" Days"

F11: 1/27/2024

Result: 9 Months, 289 Days
 
Upvote 0

Forum statistics

Threads
1,224,813
Messages
6,181,117
Members
453,021
Latest member
Justyna P

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top