Browse our Products

Aspose.Tasks for C++ 21.8 Release Notes

All Changes

KeySummaryIssue Type
TASKSNET-10327Implement reading of AutoFilters with multiple valuesEnhancement
TASKSNET-10307Fix “The given key ‘188744169’ was not present in the dictionary.” exception when open MPP documentBug
TASKSNET-10306Fix “The given key ‘1680’ was not present in the dictionary.” exception when open documentBug
TASKSNET-10303Fix StackOverflowException when creating a Project from Primavera XMLBug
TASKSNET-10286Fix Aspose.Tasks Index was outside the bounds of the arrayBug
TASKSNET-10284Fix TotalSlack not returning the proper valuesBug
TASKSNET-10283Resource Over Allocation not updated for entire rowBug
TASKSNET-4719IsOverallocated flag is True for tasks that are not overallocated for project plansBug

Public API and Backwards Incompatible Changes

The following public enumerations were added:Description
Aspose.Tasks.FilterComparisonType.IsOneOfThe value of Field equals to one of the specified Values. Used in AutoFilters.
Aspose.Tasks.TaskKey.HasOverallocatedResourceRepresents the HasOverallocatedResource (Task) field.
Aspose.Tasks.Tsk.HasOverallocatedResourceIndicates whether the task has an resource assigned which has more work on assigned tasks than can be completed within normal working capacity.

Examples and additional notes

Related issue: TASKSNET-10327 - Implement reading of AutoFilters with multiple values

FilterComparisonType.IsOneOf was added in order to represent auto filters which filter rows based on choices the user makes from a list of specific column’s values in MS Project:

Auto Filter with multiple values

auto project = System::MakeObject<Project>(System::String(u"AutoFilters.mpp"));
auto ganttView = System::DynamicCast<GanttChartView>(project->get_Views()->LINQ_FirstOrDefault([](System::SharedPtr<View> v) -> bool
    return v->get_Screen() == ViewScreen::Gantt;
auto autoFilter = ganttView->get_AutoFilters()->LINQ_FirstOrDefault([](System::SharedPtr<Filter> a) -> bool
    return a->get_Criteria()->get_Field() == Field::TaskText1;
System::Console::WriteLine(System::String::Join(u",", autoFilter->get_Criteria()->get_Values()));
// The output is
// IsOneOf
// T1,T4444

Related issue: TASKSNET-4719 - IsOverallocated flag is True for tasks that are not overallocated for project plans

We added new task field Tsk.HasOverallocatedResource in order to make overallocations-related API more clear. Sometimes a task can have overallocated resource, but task itself is not overallocated. Consider the following figure: Task1, Task2 have overallocated resource “Resource1”, but Task1 and Task2 are not overallocated.

Task3 is overallocated because Resource3 have 9h work assigned on 3 August. Obviously, Task3 also has overallocated resource “Resource3”.

Overallocations in Task Usage view

Prior to 21.8 Aspose.Tasks for C++ set Tsk.Overallocated for all that kinds of overallocation. Now Aspose.Tasks for C++ will set the properties in the following way for abovementioned example:

task1->Get(Tsk::HasOverallocatedResource()) : true
task2->Get(Tsk::HasOverallocatedResource()) : true
task3->Get(Tsk::HasOverallocatedResource()) : true

task1->Get(Tsk::IsOverallocated()) : false
task2->Get(Tsk::IsOverallocated()) : false
task3->Get(Tsk::IsOverallocated()) : true

resource1->Get(Rsc::Overallocated()) : true
resource2->Get(Rsc::Overallocated()) : false
resource3->Get(Rsc::Overallocated()) : true