In this article, we will explain How to calculate and count all Tasks in Project Schedule view in Project Server 2016 and Project Server 2013.
- 1 How to Count All Tasks in Project Server 2016?
You might also like to read Roll up Summary Task In SharePoint Task List
How to Count All Tasks in Project Server 2016?
In Project Server 2016 and 2013, to be able to calculate the total number of tasks in Project Schedule View, we will go through the following steps:
- Create an Enterprise Custom Fields.
- Build the formula for the custom field.
- Roll up the Calculation for Summary Rows.
- Add the custom field to the appropriate Task View.
- Edit your Project Schedule to calculate the formula.
As shown below, this is the output of the provided formula to Count All Tasks in Project where the total tasks for this project below the main Summary task are equal to six tasks as shown below:
Create an Enterprise Custom Field to Count All Tasks in Project Schedule
First, we are gonna create a new Enterprise Custom Field by doing the following:
- Open your PWA Site > PWA Settings.
- Below the Enterprise Data > Click on Enterprise Custom Fields and Lookup Tables.
- Click on New FIeld Button.
- Set the appropriate name for your field “Tasks Count”.
- At Entity, Select Tasks.
- At Type, Select Number.
Build Formula for the Task Count Custom Field
- At Custom Attributes, choose formula.
- In the formula text area, write the below formula
IIf([Summary], ([Task Count] - 1), 1)
In the above formula, we have calculated the Task count for a project by doing the following:
- If the current task is a summary task, calculates the task count, else show 1.
- The [Task Count] is a built-in field that used to gets the total number of tasks.
- The result of [Task Count] is always the number of tasks +1, so we use ([Task Count] – 1).
Rollup the Calculation for Summary Rows
In this step, we will choose how this field gets rolled up for summary rows including grouping summaries by doing the following:
- At Calculation for Summary Rows, choose Roll Up.
- Select Count All to calculate the total number of tasks below each summary task.
- Save your custom field.
Add Custom Field to Task Summary View
As we explained, this custom field is a task custom field that should be added to Task view like Task Summary view as the following:
- Open PWA Settings, below Look and Feel > Select Manage Views.
- Below Project Category > Click on Task Summary.
- Below Fields, Select the newly created field, then click on the add button to add it to the shown fields in this view.
- You can move the field Up and down as you prefer.
Publish Project Schedule to calculate the Custom Field Formula
If you opened your project schedule, you will note that the formula is not calculated yet as shown below:
To calculate the Project Server Custom Field Formula, you must do the following:
- Edit your Project Schedule.
- Perform a specific edit as you need.
- Click on Save, wait a moment until the Save operation completed successfully.
- Click on Publish, wait a moment until the Publish operation completed successfully.
- Then Click Close, to Check-in the Project.
Great, the newly created custom field is now calculated properly and show the Count of All Tasks in Project Schedule.
In conclusion, we have provided a simple formula to Count All Tasks in Project Schedule in
- Project Server 2016
- Project Server 2016.
- Project Server 2013.
- Project Server 2010.
- Project Online
- Install and Configure Project Server 2016 step by step
- Import Excel Sheet Into Project Server.
- Get the total number of projects in the project center, check PROJECT CENTER TOTALIZE.