Solved

# Help Calculating a value on a Report

Posted on 2013-09-02
Medium Priority
334 Views
So I have a query that results in the attached.

I want to create a report that included a Unbound Text Box (Due Date) that will Calculate:

Service ID        Due Date
IME                  Due date will be 7 calendar days from the Date of IME (it will be blank if   [/qu   no                    IME date has been entered yet)
RR                  Due date will be 10 calendar days from the Date the RR_Doctor letter is created.
ERR                Due Date will be 7 calendar days from the date the RR_Doctor letter is created.

Any help
0
Question by:seamus9909

LVL 17

Expert Comment

ID: 39459034
Wait..  You say Calendar Days..  I think you also want work days..  Most folks in the business world only want Monday through Friday.  Correct?

Kent
0

Author Comment

ID: 39459115
I have attached a sanitized version.

No they want Calendar days
Status-Report.xlsx
0

LVL 50

Accepted Solution

Dale Fye earned 2000 total points
ID: 39502153
Your [ServiceID] field in the spreadsheet does not contain the same values as you indicate above.  Generally, I would not use an unbound textbox in your report, I would create a query as the RecordSource for the report and would create a computed column in the query, something like:

DueDate:Switch([ServiceID] = "IME", IIF(ISNULL([Date of IME]), NULL, DateAdd("d", 7, [Date of IME])), [ServiceID] = "RR", DateAdd("d", 10, [LastOfDateCreated]), [ServiceID] = "ERR", DateAdd("d", 7, [LastOfDateCreated]), True, "Unknown")

This assumes that the "Date the RR_Doctor letter is created" you mentioned in your original post is the [LastOfDateCreated] field in your spreadsheet.
0

## Featured Post

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.