Handling Overtime, Remaining Costs and Work
Contents
[
Hide
Show
]Handling Overtime, Remaining Costs and Work
The Asn class exposes a number of properties for handling an assignment’s overtime, remaining costs and work:
- OvertimeCost represents the sum of the actual and remaining overtime costs of an assignment (decimal).
- OvertimeWork represents the scheduled overtime work for an assignment (TimeSpan).
- RemainingCost represents the remaining projected cost for completing an assignment (decimal).
- RemainingOvertimeCost represents the remaining projected overtime cost for completing an assignment (decimal).
- RemainingWork represents the scheduled remaining work for an assignment (TimeSpan).
- RemainingOvertimeWork represents the scheduled remaining overtime work for an assignment (TimeSpan).
To see assignment overtime, remaining cost and work in Microsoft Project:
- On the Task Usage screen, select the Insert menu, then Column.
- Add the desired columns.
Getting Assignment Overtimes in Aspose.Tasks
The following example shows how to get assignment overtimes, remaining costs and work using Aspose.Tasks.
1Project project = new Project("New Project.mpp");
2
3// Print assignment overtimes
4foreach (ResourceAssignment ra in project.ResourceAssignments)
5{
6 Console.WriteLine(ra.Get(Asn.OvertimeCost));
7 Console.WriteLine(ra.Get(Asn.OvertimeWork).ToString());
8 Console.WriteLine(ra.Get(Asn.RemainingCost));
9 Console.WriteLine(ra.Get(Asn.RemainingOvertimeCost));
10 Console.WriteLine(ra.Get(Asn.RemainingOvertimeWork).ToString());
11 Console.WriteLine(ra.Get(Asn.RemainingOvertimeWork).ToString());
12}