Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 7
Default if statements returning dates

i have the following formula to give a 2 day cycle for production which will
skip saturdays and sundays. can it be made to miss other days such as public
holidays also if they are put into a table or something.

IF(WEEKDAY(A1+2)=7,A1+4,IF(WEEKDAY(A1+2)=1,A1+4,A1 +2))

whe A1 is first date, formula is in B1:Z1
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,389
Default if statements returning dates

Yes it can if you use NETWORKDAYS. You will need to have the Analysis
ToolPak installed, unless you have XL2007. Look it up in help for more
information.

Regards,
Fred.

"Clinton" wrote in message
...
i have the following formula to give a 2 day cycle for production which
will
skip saturdays and sundays. can it be made to miss other days such as
public
holidays also if they are put into a table or something.

IF(WEEKDAY(A1+2)=7,A1+4,IF(WEEKDAY(A1+2)=1,A1+4,A1 +2))

whe A1 is first date, formula is in B1:Z1


  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 15,768
Default if statements returning dates

See Excel help on the WORKDAY function.

It returns the date serial number n days if the future and has an option to
account for holidays.

You have to format the result as a date.

--
Biff
Microsoft Excel MVP


"Clinton" wrote in message
...
i have the following formula to give a 2 day cycle for production which
will
skip saturdays and sundays. can it be made to miss other days such as
public
holidays also if they are put into a table or something.

IF(WEEKDAY(A1+2)=7,A1+4,IF(WEEKDAY(A1+2)=1,A1+4,A1 +2))

whe A1 is first date, formula is in B1:Z1



  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 7
Default if statements returning dates

thank you very much. worked perfect.

"T. Valko" wrote:

See Excel help on the WORKDAY function.

It returns the date serial number n days if the future and has an option to
account for holidays.

You have to format the result as a date.

--
Biff
Microsoft Excel MVP


"Clinton" wrote in message
...
i have the following formula to give a 2 day cycle for production which
will
skip saturdays and sundays. can it be made to miss other days such as
public
holidays also if they are put into a table or something.

IF(WEEKDAY(A1+2)=7,A1+4,IF(WEEKDAY(A1+2)=1,A1+4,A1 +2))

whe A1 is first date, formula is in B1:Z1




  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 15,768
Default if statements returning dates

You're welcome!

--
Biff
Microsoft Excel MVP


"Clinton" wrote in message
...
thank you very much. worked perfect.

"T. Valko" wrote:

See Excel help on the WORKDAY function.

It returns the date serial number n days if the future and has an option
to
account for holidays.

You have to format the result as a date.

--
Biff
Microsoft Excel MVP


"Clinton" wrote in message
...
i have the following formula to give a 2 day cycle for production which
will
skip saturdays and sundays. can it be made to miss other days such as
public
holidays also if they are put into a table or something.

IF(WEEKDAY(A1+2)=7,A1+4,IF(WEEKDAY(A1+2)=1,A1+4,A1 +2))

whe A1 is first date, formula is in B1:Z1








Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Using dates in IF statements altah Excel Discussion (Misc queries) 3 July 16th 07 03:16 AM
Nested If statements returning a sum calculation arkage Excel Worksheet Functions 1 April 20th 07 08:59 PM
Returning text from nested IF and Vlookup statements Patricia Excel Worksheet Functions 10 July 28th 06 04:22 PM
If statements and Dates Sue New Users to Excel 4 April 21st 06 05:02 PM
Returning expected dates London Excel Worksheet Functions 1 July 23rd 05 03:31 AM


All times are GMT +1. The time now is 07:20 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"