Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.misc
|
|||
|
|||
Workdays not working as expected
Help!
(running Office 2003 on XP) I am trying to calculate 11 workdays from a given date. Some holidays we work, some we don't. We shut down for up to two weeks at Christmas. I put in the workday formula as I think it to be. The result isn't what I expected. Lets say I put the date to start in cell A1, for example 1/5/09 In cell B1 I insert the following =workday(a1,11,0) The result displayed 1/20/09 so, I stuck in an extra holiday or two =workday(a1,11,1) displays 1/20/09. =workday(a1,11,2) displays 1/20/09. =workday(a1,11,10) displays 1/20/09. =workday(a1,11) displays 1/20/09. Where am I going wrong? Changing the -- |
#2
Posted to microsoft.public.excel.misc
|
|||
|
|||
Workdays not working as expected
The holidays argument should be a reference to a range where you list the
actual dates for the holidays. Lets assume 1/1/2009 and 1/2/2009 are holidays. List those dates in a range of cells: J1 = 1/1/2009 J2 = 1/2/2009 Then you refer to that range like this: =WORKDAY(A1,11,J1:J2) -- Biff Microsoft Excel MVP "Rotata" wrote in message ... Help! (running Office 2003 on XP) I am trying to calculate 11 workdays from a given date. Some holidays we work, some we don't. We shut down for up to two weeks at Christmas. I put in the workday formula as I think it to be. The result isn't what I expected. Lets say I put the date to start in cell A1, for example 1/5/09 In cell B1 I insert the following =workday(a1,11,0) The result displayed 1/20/09 so, I stuck in an extra holiday or two =workday(a1,11,1) displays 1/20/09. =workday(a1,11,2) displays 1/20/09. =workday(a1,11,10) displays 1/20/09. =workday(a1,11) displays 1/20/09. Where am I going wrong? Changing the -- |
#3
Posted to microsoft.public.excel.misc
|
|||
|
|||
Workdays not working as expected
Thank you much for the example. Not only does it work beautifully, I now have
a better understanding of "range". -- "T. Valko" wrote: The holidays argument should be a reference to a range where you list the actual dates for the holidays. Lets assume 1/1/2009 and 1/2/2009 are holidays. List those dates in a range of cells: J1 = 1/1/2009 J2 = 1/2/2009 Then you refer to that range like this: =WORKDAY(A1,11,J1:J2) -- Biff Microsoft Excel MVP "Rotata" wrote in message ... Help! (running Office 2003 on XP) I am trying to calculate 11 workdays from a given date. Some holidays we work, some we don't. We shut down for up to two weeks at Christmas. I put in the workday formula as I think it to be. The result isn't what I expected. Lets say I put the date to start in cell A1, for example 1/5/09 In cell B1 I insert the following =workday(a1,11,0) The result displayed 1/20/09 so, I stuck in an extra holiday or two =workday(a1,11,1) displays 1/20/09. =workday(a1,11,2) displays 1/20/09. =workday(a1,11,10) displays 1/20/09. =workday(a1,11) displays 1/20/09. Where am I going wrong? Changing the -- |
#4
Posted to microsoft.public.excel.misc
|
|||
|
|||
Workdays not working as expected
You're welcome. Thanks for the feedback!
-- Biff Microsoft Excel MVP "Rotata" wrote in message ... Thank you much for the example. Not only does it work beautifully, I now have a better understanding of "range". -- "T. Valko" wrote: The holidays argument should be a reference to a range where you list the actual dates for the holidays. Lets assume 1/1/2009 and 1/2/2009 are holidays. List those dates in a range of cells: J1 = 1/1/2009 J2 = 1/2/2009 Then you refer to that range like this: =WORKDAY(A1,11,J1:J2) -- Biff Microsoft Excel MVP "Rotata" wrote in message ... Help! (running Office 2003 on XP) I am trying to calculate 11 workdays from a given date. Some holidays we work, some we don't. We shut down for up to two weeks at Christmas. I put in the workday formula as I think it to be. The result isn't what I expected. Lets say I put the date to start in cell A1, for example 1/5/09 In cell B1 I insert the following =workday(a1,11,0) The result displayed 1/20/09 so, I stuck in an extra holiday or two =workday(a1,11,1) displays 1/20/09. =workday(a1,11,2) displays 1/20/09. =workday(a1,11,10) displays 1/20/09. =workday(a1,11) displays 1/20/09. Where am I going wrong? Changing the -- |
#5
Posted to microsoft.public.excel.misc
|
|||
|
|||
Workdays not working as expected
For any Excel function (except DATEDIF) on which you need extra information,
you should always start by looking at the Excel help for that function. It will explain the syntax, give examples, and often have a "See also" link to related functions. -- David Biddulph "Rotata" wrote in message ... Thank you much for the example. Not only does it work beautifully, I now have a better understanding of "range". "T. Valko" wrote: The holidays argument should be a reference to a range where you list the actual dates for the holidays. Lets assume 1/1/2009 and 1/2/2009 are holidays. List those dates in a range of cells: J1 = 1/1/2009 J2 = 1/2/2009 Then you refer to that range like this: =WORKDAY(A1,11,J1:J2) .... |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Code not working as expected. | Excel Discussion (Misc queries) | |||
Help !!! My code is not working as expected. | Excel Discussion (Misc queries) | |||
Iserror not working as expected | Excel Worksheet Functions | |||
=NETWORKDAYS not working as expected and as it once did | Excel Worksheet Functions | |||
Lookup Not working as expected | New Users to Excel |