Link to home
Start Free TrialLog in
Avatar of AliciaVee
AliciaVee

asked on

Days Remaining in Project 2007

I'm trying to calculate how many days remaining from the current date, to the finish date of a specific task.   I've tried many variations and somehow keep getting more days (in some instances) than what is the total duration for the task.  Example: duration = 18 days, yet for Days Remaining I get 148.  In some tasks...the duration matches the date remaining...which is wrong.

Here is what I'm using.  I also tried many variations of DateDiff
[Finish]-[Current Date]
or
[Finish]-Now()

Same wrong results (am using a Number field)
Avatar of Neil Russell
Neil Russell
Flag of United Kingdom of Great Britain and Northern Ireland image

Avatar of barry houdini
A simple subtraction should be all you need in Excel. If you have a future finish date in cell A2 then this formula should give the number of days until that date

=A2-TODAY()

format result cell as general

regards, barry
Avatar of AliciaVee
AliciaVee

ASKER

Neilsar -- I did come across the link you shared, as I tried searching for a solution before posting a request for help.  That link describes adding more time to a duration already in progress -- I need something that calculates based on today's date and the confirmed finished dates -- how many days are left.  If a task starts on 3/1 and ends on 3/15 it will show (roughly) 15 days...but if today is 3/12, then the new field should have 3 as the value.

barryhoudini -- you are providing an excel formula -- and the simple calculation is what I presented as my starting point -- didn't work.
Can I clarify Alicia, are you looking to do this in Excel (your question is tagged with "Microsoft Excel Spreadsheet Software")?

If you have two dates in excel then subtracting the earlier one from the later one will always give you the difference in days - if that doesn't work then it probably means that your "dates" aren't really dates or are being misinterpreted by excel

regards, barry
sorry barry -- not sure how this question got tagged in the Excel area -- should only be MS Project 2007
okay...thanks.
Okay -- so I found the formula that will provide what I need located here:
http://blogs.msdn.com/b/project_programmability/archive/2012/05/10/9888826.aspx

However, now I need to adjust to compensate for when the task is complete -- I don't want it to show -53 days....I can add a 0, but ideally I would like to add a * to indicate it is complete.  a 0 value may appear that there are no days left before due date.  I think this means I have to use a text field to get the * -- not sure I can get it to work.  Any takers?

current formula:
((F([% Complete]=100,0,DateDiff("d",NOW(),[Finish]))
Hi,

if you don't need to do any calculations with your formula result, you can use a text field with this formula:

IIf([% Complete]=100;"*";DateDiff("d";date();[Finish]) & "d")

Regards

Thomas
ASKER CERTIFIED SOLUTION
Avatar of Anastasia D. Gavanas
Anastasia D. Gavanas
Flag of Greece image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial