You are here:

Excel/Subtracting a fix number of days from a date, without weekends

Advertisement


Question
QUESTION: Hi.
What is the formula to subtract fix amount of days from a date, excluding Jewish weekends (Friday, Saturday).
For example: May 10 2015 minus 2 days = May 6 2015.
Thanks
Moshe

ANSWER: This used to be quite tricky, but is now easier thanks to the workday.intl function - if you visit http://www.excelfunctions.net/Excel-Workday-Intl-Function.html you will see how this works.  NOTE that this was introduced in office 2010, if you have an earlier version then a more complicated formula would be needed.

---------- FOLLOW-UP ----------

QUESTION: Thanks Aidan.
I believe that the workday.intl function counts the number of days between two dates.
However, I wish to have the date, if you subtract X days from a specific date.
For example: 12/05/2015-1=11/15/2015.
Any idea?

Answer
I very nearly gave you the wrong answer, which would have been networkdays.intl - it is this that counts days between two dates.  From the site I referenced

The Excel Workday.Intl function returns a date that is a supplied number of working days (excluding weekends and holidays) ahead of a given start date. The function allows the user to specify which days are counted as weekends.

The function is new in Excel 2010 and so is not available in earlier versions of Excel. However, it is similar to the Workday function, which is available in earlier versions of Excel.


That description is actually wrong, as they specified AHEAD of a given start date - but as you can use negative numbers, the formula wiil work for ahead of or before

so if your 12th May was in A1

=WORKDAY.INTL(A1,-2,7)

would give you the result you wanted.
About Excel
This topic answers questions related to Microsoft Excel spreadsheet (or workbook) stand-alone or Mircrosoft Office Excel including Excel 2003, Excel 2007, Office 2000, and Office XP. You can get Excel help on Excel formulas(or functions), Excell macros, charting in Excel, advanced features, and the general use of Excel. This does not provide a general Excel tutorial nor the basics of using a spreadsheet. It provides specific answers to using Microsoft Excel only. If you do not see your Excel question answered in this area then please ask an Excel question here

Excel

All Answers


Answers by Expert:


Ask Experts

Volunteer


Aidan Heritage

Expertise

I have provided first hand support since `95 for Microsoft Office majoring in Word and Excel - support for all versions from 2 onwards. I'm based in the UK, so please allow for time differences when asking me questions from other parts of the world!

Experience

My background is in the insurance industry and call centre areas, but have been called upon to provide many varied solutions.

Education/Credentials
I'm educated to UK A level standard, but as I left school some 30 years ago that is rather irrelevent - university of life has provided more of a background!

©2016 About.com. All rights reserved.