Flag New Tasks Starting Next Week MSP 2010

L
Lee Wilson 👤 Member for 11 years 6 months

Hi All,

As title suggests I'm looking to implement a new flag to show tasks (excluding group headers) which are due to start the next working week.

I don't want to show any tasks currently in progress, jut new ones starting next working week.

Any ideas ?

Thanks

L
Lee Wilson 👤 Member for 11 years 6 months

Thanks for the tip. This appears to work just as requested. I presume when we move into the new calendar year  - past the described week 52 into week 1 issue, then things return to normal. If thats the case then there is no issue as nothing happens for us in week 52-1 inclusive, due to Christmas furlough (exception in place). 

T
Tom Boyle 👤 Member for 19 years 6 months

The hard part of your question is the "next working week" interval.  Fortunately, MSP allows the Datepart function from vba in custom field formulas, and with that we can get calendar-year week numbers.  Then we just want to trigger the flag for all tasks starting this year and starting in the week numbered one higher than the one we are in.  This seems to work except at the end of the year (the week no. 52/53/1 transition).  Apply this formula in a custom flag field:

IIf(Datepart("yyyy",[Start],2,2)=Datepart("yyyy",Now(),2,2) And Datepart("ww",[Start],2,2)=Datepart("ww",Now(),2,2)+1,"Yes","No")

You can refer to this document for fine adjustments to your work week interval and week numbering standard (the 2,2 in the formula):

https://msdn.microsoft.com/en-us/library/20ee97hz%28v=vs.90%29.aspx?f=2…

 

Obviously, this may need a little tweek to fix the year-end issue (and to exclude summary tasks, etc.)

Good luck, tom

Forum Sponsor

Top Posters

Julian Pegg
1 posts
Peter Nagy
2 posts
Raymund de Laza
17 posts
Syed_Asad
0 posts
Tony Greyvenstein
0 posts
Ahmed Al-Jubouri
13 posts
Umar Alvi
3 posts
Sibusiso Mahlalela
0 posts
Michael Samanyayi
3 posts
Simon Gumede
0 posts