Wednesday, July 11, 2012

Getting the SharePoint Tasks to Order like MS Project Tasks

When you create a schedule in MS Project, each task you create has a number associated with it to help you keep track of its ordinal position within the plan. This is so helpful that most folks associate this behavior as part of any task list.

So it may come as a surprise that the default SharePoint task list doesn't.

Now, that's not entirely true, as each task in a SharePoint task list does in fact have an ID. But it's not the same as the ordinal value within MS Project. Rather, it is the unique ID value for that item within the SharePoint task list. Worse yet, the default view for a task list sorts on this SharePoint ID value. This means the very first time you share an MS Project plan to SharePoint, the task ordering will match within the SharePoint task list. However, as you move things around within MS Project, you will notice the SharePoint task list becomes more and more detached from your expected sorting.

The solution? Put in your own ordinal support with our IntelliGantt Add In and Web Part. Here's how:

First create an Ordinal column in your SharePoint task list:

Next, within your shared MS Project plan, click on the settings to bring up the big fields dialog. Note the 'Ordinal' field at the top of the list:

Click on the checkbox cell in the 'To SharePoint' column. This will send the MS Project Task ID values to the SharePoint Ordinal column. (The Add In does not support 'From SharePoint at this time):

Save the settings. Now we will want to send the MS Project task ids to SharePoint. So click the 'Upload' button in the add in:

Now when we view the plan in SharePoint we will see the exact same MS Project task ids in the Ordinal column:

So why did we have to call it 'Ordinal' again? Because SharePoint already has its own ID field. In fact, we have one more thing to do-- change the view associated with the task list to sort by our Ordinal value instead of the built-in SharePoint ID:

Done! Now the task order in your SharePoint task list and IntelliGantt Web Part will always match the same task order in MS Project