Welcome to the Smartsheet Forum Archives


The posts in this forum are no longer monitored for accuracy and their content may no longer be current. If there's a discussion here that interests you and you'd like to find (or create) a more current version, please Visit the Current Forums.

Adding Workdays to a Formula

Options
Ray Rios
Ray Rios
edited 12/09/19 in Archived 2017 Posts

Hi SmartPeople -

I am trying to create a formula that adds "work days" to a date.

Example: I have a "Date Reported" column and a "Date Due" column. The "Date Due" column is a formula based column that should add a specific number of days (either 5, 10, or 20) based on a given priority in the "Priority" column. However, instead of adding "calendar days", I need it to add "workdays".

This is the formula currently using: =IF(Priority3 = "red", [Date Reported]3 + 5, IF(Priority3 = "yellow", [Date Reported]3 + 10, IF(Priority3 = "green", $[Date Due]$2 + 20, IF(Priority3 = "gray", [Date Reported]3 + 20))))

How do I change the formula?

Comments

  • Mike Wilday
    Mike Wilday ✭✭✭✭✭✭
    edited 05/11/17
    Options

    You will need to use the following formula to calculate the additional workdays. 

    Workday([Date Reported]3, 5)

    That will add 5 working days to the Date Reported column (row 3) and return the new date. You will need to replace each of your than statements with that formula.  

    I.E. 

    =IF(Priority3 = "red", Workday([Date Reported]3, 5), IF(Priority3 = "yellow", Workday([Date Reported]3, 10), IF(Priority3 = "green", Workday($[Date Due]$2 , 20), IF(Priority3 = "gray", Workday([Date Reported]3, 20)))))

    That should work for you.

This discussion has been closed.