Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
hi. i need to create a macro that will alow me to find the difference
in days between two given dates. is this possible? thanks |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
if the dates are in A1 and B1, then
=MAX(A1,B1)-MIN(A1,B1) -- Gary''s Student - gsnu200764 "tc" wrote: hi. i need to create a macro that will alow me to find the difference in days between two given dates. is this possible? thanks |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Just subtract them
Dim Date1 as date dim Date2 as date date1 = dateserial(2007,12,25) date2 = dateserial(2008,1,13) msgbox date2 - date1 '+ 1 Is the 3rd - 1st a difference of 3 days or 2 days? tc wrote: hi. i need to create a macro that will alow me to find the difference in days between two given dates. is this possible? thanks -- Dave Peterson |
#4
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Why not just this...
=ABS(B1-A1) instead? Rick "Gary''s Student" wrote in message ... if the dates are in A1 and B1, then =MAX(A1,B1)-MIN(A1,B1) -- Gary''s Student - gsnu200764 "tc" wrote: hi. i need to create a macro that will alow me to find the difference in days between two given dates. is this possible? thanks |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Difference between two dates | Excel Discussion (Misc queries) | |||
Difference between two dates | Excel Discussion (Misc queries) | |||
Difference between dates | Excel Worksheet Functions | |||
Difference of two dates | Excel Worksheet Functions | |||
Difference of two dates | Excel Discussion (Misc queries) |