Tag Archives | Week numbers

Week Numbers in Microsoft Project

Microsoft Project does not have a generic way of displaying week numbers, but some project managers may need to display what week in the year or week of the project a task date corresponds to.  What you have to do is create a custom text field then set it to display a formula. I’ve shown before you how to create a custom field but I’ll do this again here.

Displaying Week Numbers using a formula

Creating a Custom Text Field

To create a custom field, right-click on any of the existing column titles in the Gantt Chart grid and choose Custom Fields from the pop-up menu.

Custom Field dialog for week numbersIn the top-right drop-down selector choose Text.

Now click on the first available field in the list – here Text1 is selected – and then click on the Rename… button. Give the field a suitable name. here I’ve called it Week Number.

Next you need to select the Custom attribute of Formula  by clicking on the Formula button.Formula for week numbers

Here is a suggested formula to show the week number relative to the project’s start date:

"Week " & CStr(1+datediff("w",[Project Start],[Start]))

You might only want the week number to go no higher than 52 so change the formula to use the MOD function like this:

"Week " & CStr(1+datediff("w",[Project Start],[Start]) Mod 52)

Here is an alternative formula to show the week number in relation to the calendar year of the year the project started:

"Week " & CStr(1+datediff("w",DateSerial(Year([Project Start]),1,1),[Start]))


Of course if you only want the week number and no text before it omit the    “Week ” &    in the formula.

Having now created the custom field, right-click on the column title where you want to display your new field and select Insert Field from the pop-up menu. Scroll down the list of field names and select your new field. As you renamed a Text field it will still appear with all the other default text fields in the listing so my example above would appear as Text1 (Week Number) in the list.