TaskLink Class

Represents a predecessor link.
Inheritance Hierarchy
SystemObject
  Aspose.TasksTaskLink

Namespace:  Aspose.Tasks
Assembly:  Aspose.Tasks (in Aspose.Tasks.dll) Version: 21.5
Syntax
public class TaskLink : IEquatable<TaskLink>

The TaskLink type exposes the following members.

Properties
  NameDescription
Public propertyCode exampleCrossProjectName
Gets or sets the external predecessor project.
Public propertyCode exampleIsCrossProject
Gets or sets a value indicating whether a predecessor is part of another project.
Public propertyCode exampleLagFormat
Gets or sets the format for expressing the lag format.
Public propertyCode exampleLinkLag
Gets or sets the amount of lag in tenths of a minute.
Public propertyCode exampleLinkType
Gets or sets the type of a link.
Public propertyCode examplePredTask
Gets or sets the predecessor task.
Public propertyCode exampleSuccTask
Gets or sets the successor task.
Methods
  NameDescription
Public methodCode exampleEquals(Object)
Returns a value indicating whether this instance is equal to a specified object.
(Overrides ObjectEquals(Object).)
Public methodCode exampleEquals(TaskLink)
Returns a value indicating whether this instance is equal to a specified object.
Protected methodFinalize (Inherited from Object.)
Public methodCode exampleGetHashCode
Returns a hash code value for the instance of the TaskLink class.
(Overrides ObjectGetHashCode.)
Public methodGetType (Inherited from Object.)
Protected methodMemberwiseClone (Inherited from Object.)
Public methodCode exampleToString
Returns string representation of a TaskLink. The exact details of the representation are unspecified and subject to change.
(Overrides ObjectToString.)
Examples
Shows how to read project task links.
var project = new Project(DataDir + "GetPredecessorSuccessorTasks.mpp");

// Display names of predecessor and successor tasks
foreach (var taskLink in project.TaskLinks)
{
    Console.WriteLine("Predecessor: " + taskLink.PredTask.Get(Tsk.Name));
    Console.WriteLine("Successor: " + taskLink.SuccTask.Get(Tsk.Name));
    Console.WriteLine("Lag Format: " + taskLink.LagFormat);
    Console.WriteLine("Link Lag: " + taskLink.LinkLag);
    Console.WriteLine();
}
See Also