Browse our Products

Aspose.Tasks for C++ 21.6 Release Notes

All Changes

KeySummaryIssue Type
TASKSNET-4903Add ExecutingWebRequest event for interactions with API of ProjectOnline \ ProjectServer.Enhancement
TASKSNET-4696Add support of ‘Display OLE as Icon’ propertyEnhancement
TASKSNET-4908Fix resaving of the specific MPP file throws ArgumentOutOfRangeExceptionBug
TASKSNET-4907Fix resaving of the specific MPP file throws ‘Project writing exception’Bug
TASKSNET-4904Fix OLE object frame remains even after removing ole objectBug
TASKSNET-4876Fix incorrect timephased data for assignment with zero work.Bug
TASKSNET-4866Fix setting of assigned task duration not recalculating correctly for the first taskBug
TASKSNET-4854Fix updating of assignment’s TimephasedDataBug
TASKSNET-4850Fix “File reading error.” exception when open document MPX fileBug
TASKSNET-4734Fix failed resave to MPX formatBug
TASKSNET-4698Fix incorrect percentages in exported MPP fileBug

Public API and Backwards Incompatible Changes

The following public types were added:Description
Aspose.Tasks.Visualization.FillPatternFill pattern used in middle shape of a gantt bar.
Aspose.Tasks.Visualization.HorizontalAlignmentSpecifies how an object or text is horizontally aligned relative to another object.
Aspose.Tasks.Visualization.VisualObjectPlacementRepresents placement and appearance of in a view.
Aspose.Tasks.WebRequestEventArgsProvides arguments for the event that is raised when the client sends a web request to the Project Server’s web API.
The following public methods and properties were added:Description
Aspose.Tasks.OleObject.IdGets the object id.
Aspose.Tasks.OleObject.DisplayAsIconGets a flag indicating that OLE object should be shown either as an icon or as its regular picture.
Aspose.Tasks.ProjectServerManager.ExecutingWebRequestAn event that is raised when the web request is sent to Project Server’s web API.
Aspose.Tasks.View.VisualObjectsPlacementsGets a collection of objects representing placement and appearance of in the view.
Aspose.Tasks.Visualization.VisualObjectPlacement.OleObjectIdGets Id of object.
Aspose.Tasks.Visualization.VisualObjectPlacement.TaskIdGets Id of task if ‘Attach to task’ options is selected, -1 otherwise.
Aspose.Tasks.Visualization.VisualObjectPlacement.WidthGets displayed width of visual object.
Aspose.Tasks.Visualization.VisualObjectPlacement.HeightGets displayed height of visual object.
Aspose.Tasks.Visualization.VisualObjectPlacement.VerticalOffsetGets vertical offset of visual object.
Aspose.Tasks.Visualization.VisualObjectPlacement.HorizontalOffsetGets horizontal offset of visual object.
Aspose.Tasks.Visualization.VisualObjectPlacement.TimescaleDateGets date placement of visual object when ‘Attach to timescale’ options is selected.
Aspose.Tasks.Visualization.VisualObjectPlacement.AttachmentPointGets alignment of visual object relative to a task when ‘Attach to task’ options is selected.
Aspose.Tasks.Visualization.VisualObjectPlacement.BorderLineColorGets border line color.
Aspose.Tasks.Visualization.VisualObjectPlacement.BorderLineThicknessGets border line thickness (allowed values are 0 - 5).
Aspose.Tasks.Visualization.VisualObjectPlacement.FillColorGets fill color. Set to to set the fill to ‘None’.
Aspose.Tasks.Visualization.VisualObjectPlacement.FillPatternGets fill pattern.
Aspose.Tasks.WebRequestEventArgs.WebRequestGets a web request to sent to the Project Server’s web API.
The following public enumerations were added:Description
Aspose.Tasks.TaskKey.SVRepresents the SV (Task) field.
Aspose.Tasks.Tsk.SVThe earned value schedule variance, through the project status date.
Aspose.Tasks.Visualization.FillPattern.HollowHollow pattern.
Aspose.Tasks.Visualization.FillPattern.SolidFillSolid fill pattern.
Aspose.Tasks.Visualization.FillPattern.LightFillLight fill pattern.
Aspose.Tasks.Visualization.FillPattern.MediumFillMedium fill pattern.
Aspose.Tasks.Visualization.FillPattern.DarkFillDark fill pattern.
Aspose.Tasks.Visualization.FillPattern.DiagonalLeftDiagonal left pattern.
Aspose.Tasks.Visualization.FillPattern.DiagonalRightDiagonal right pattern.
Aspose.Tasks.Visualization.FillPattern.DiagonalCrossDiagonal cross pattern.
Aspose.Tasks.Visualization.FillPattern.LineVerticalLine vertical pattern.
Aspose.Tasks.Visualization.FillPattern.LineHorizontalLine horizontal pattern.
Aspose.Tasks.Visualization.FillPattern.LineCrossLine cross pattern.
Aspose.Tasks.Visualization.FillPattern.SolidFillWithDashedBorderSolid with dashed border pattern.
Aspose.Tasks.Visualization.HorizontalAlignment.LeftThe object is aligned on the left of the target element.
Aspose.Tasks.Visualization.HorizontalAlignment.RightThe object is aligned on the right of the target element.

Examples and additional notes

Related issue: TASKSNET-4903 - Add ExecutingWebRequest event for interactions with API of ProjectOnline \ ProjectServer.

Now you can specify custom callback for WebRequest issued during interaction with Project Online \ Project Server via Project Web Access API:

    System::MulticastDelegate<void(System::SharedPtr<Object>, System::SharedPtr<WebRequestEventArgs>)> handler([](System::SharedPtr<Object> o, System::SharedPtr<WebRequestEventArgs> e){
        e->get_WebRequest()->get_Headers()->Add(u"XMyCustomHeader", u"testvalue");
    });    
    auto credentials = System::MakeObject<ProjectServerCredentials>(u"http://myprojectserver/sites/pwa", u"user", u"pwd");
    auto manager = System::MakeObject<ProjectServerManager>(credentials);
    manager->ExecutingWebRequest.connect(handler);
Related issue: TASKSNET-4696 - Add support of ‘Display OLE as Icon’ property.

Now you can read OleObject’s DisplayAsIcon property to determine whether OLE object should be displayed as icon or as its regular picture. Also new entity was introduced: VisualObjectPlacement which represents visual object’s (including OleObject) placement and apperance in a project’s view. It corresponds to “Format Drawing” dialog window called by “Properties” command from OleObject’s (or another visual object in a view) context menu:

Format Drawing

    auto project = System::MakeObject<Project>(System::String(u"ProjectWithOleObjects.mpp"));
    auto view = project->get_Views()->LINQ_First([](System::SharedPtr<View> v) -> bool
    {
        return v->get_Name() == u"&Gantt Chart";
    });
    auto oleObject = project->get_OleObjects()->LINQ_First([](System::SharedPtr<OleObject> o) -> bool
    {
        return o->get_Id() == 1;
    });

    System::Console::WriteLine(u"First OLE object: {0}", oleObject->get_Name());
    System::Console::WriteLine(u"DisplayAsIcon: {0}", oleObject->get_DisplayAsIcon());

    auto oleObjectPlacement = view->get_VisualObjectsPlacements()->LINQ_First([](System::SharedPtr<Aspose::Tasks::Visualization::VisualObjectPlacement> v) -> bool
    {
        return v->get_OleObjectId() == 1;
    });

    System::Console::WriteLine(u"BorderLineColor: {0}", oleObjectPlacement->get_BorderLineColor());
    System::Console::WriteLine(u"BorderLineColor: {0}", oleObjectPlacement->get_BorderLineThickness());

    if (oleObjectPlacement->get_TaskId() > 0)
    {
        System::Console::WriteLine(u"Attached to task: {0}", oleObjectPlacement->get_TaskId());
    }
    else
    {
        System::Console::WriteLine(u"Attached to timescale date: {0}", oleObjectPlacement->get_TimescaleDate());
    }