smide

Board Regular
Joined
Dec 20, 2015
Messages
162
Office Version
  1. 2016
Platform
  1. Windows
Hello.




In cell A1 I have current date created with formula =today() eg. 3-Oct-2019.
In the same column starting from cell A3 (A3:A600) I have dates and time in format dd.mm.yyyy - hh:mm (example. 04.10.2019 - 21:00).


All those cells (A3:A600) are text cells. I need to subtract all those dates (A3:A600) and current date. Result(s) should be the difference expressed in days (column B).


example.

AB
1
3-Oct-2019
2
330.09.2019 - 17:30-3
401.10.2019 - 22:00-2
502.10.2019 - 16:00-1
602.10.2019 - 21:00-1
703.10.2019 - 12:000
804.10.2019 - 16:451
905.10.2019 - 13:002

<tbody>
</tbody>

 
Last edited:

Excel Facts

Easy bullets in Excel
If you have a numeric keypad, press Alt+7 on numeric keypad to type a bullet in Excel.
Hi, you may need to format the cells that contain the formula as general or number.


Excel 2013/2016
AB
1
203-Oct-19
3
430.09.2019 - 17:30-3
501.10.2019 - 22:00-2
602.10.2019 - 16:00-1
702.10.2019 - 21:00-1
803.10.2019 - 12:000
904.10.2019 - 16:451
1005.10.2019 - 13:002
Sheet1
Cell Formulas
RangeFormula
A2=TODAY()
B4=SUBSTITUTE(LEFT(A4,10),".","/")-$A$2
 
Upvote 0
Tried everything but unfortunately I'm getting only error (#VALUE!) as a result...:confused:
 
Upvote 0
Tried everything but unfortunately I'm getting only error (#VALUE!) as a result...:confused:

Let's try a method that is not susceptible to regional date/time settings.


Excel 2013/2016
AB
103/10/2019
2
330.09.2019 - 17:30-3
401.10.2019 - 22:00-2
502.10.2019 - 16:00-1
602.10.2019 - 21:00-1
703.10.2019 - 12:000
804.10.2019 - 16:451
905.10.2019 - 13:002
Sheet1
Cell Formulas
RangeFormula
B3=DATE(MID(A3,7,4),MID(A3,4,2),LEFT(A3,2))-$A$1
 
Last edited:
Upvote 0
Works great! Thank you so much.(y)
 
Upvote 0

Forum statistics

Threads
1,213,489
Messages
6,113,952
Members
448,535
Latest member
alrossman

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