Class ExtendedAttribute

Class ExtendedAttribute

Namespace: Aspose.Tasks
Assembly: Aspose.Tasks.dll (25.2.0)

Represents extended attributes.

[ClassInterface(ClassInterfaceType.AutoDual)]
public class ExtendedAttribute

Inheritance

objectExtendedAttribute

Inherited Members

object.GetType(), object.MemberwiseClone(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()

Remarks

Currently supported all types of Extended attributes reading from MSP Xml 2003/2007 and mpp 2003. For MSP mpp 2007 all Extended attributes reading supported except durations and flags.

Properties

AttributeDefinition

Gets the attribute definition.

public ExtendedAttributeDefinition AttributeDefinition { get; }

Property Value

ExtendedAttributeDefinition

DateValue

Gets or sets a value for attributes with date types (Date, Start, Finish).

public DateTime DateValue { get; set; }

Property Value

DateTime

Exceptions

InvalidOperationException

Thrown if the Aspose.Tasks.ExtendedAttribute.AttributeDefinition property is not initialized or current attribute is not an date attribute.

DurationValue

Gets or sets value for attributes with ‘Duration’ type.

public Duration DurationValue { get; set; }

Property Value

Duration

Exceptions

InvalidOperationException

Thrown if the Aspose.Tasks.ExtendedAttribute.AttributeDefinition property is not initialized or custom field type of Aspose.Tasks.ExtendedAttribute.AttributeDefinition property is not a Aspose.Tasks.Duration instance.

FieldId

Gets the id of a field.

public string FieldId { get; }

Property Value

string

FlagValue

Gets or sets a value indicating whether a flag is set for an attribute with ‘Flag’ type.

public bool FlagValue { get; set; }

Property Value

bool

Exceptions

InvalidOperationException

Thrown if the Aspose.Tasks.ExtendedAttribute.AttributeDefinition property is not initialized or current attribute is not a flag attribute.

IsErrorValue

Gets whether calculation of extended attribute’s value resulted in an error.

public bool IsErrorValue { get; }

Property Value

bool

NumericValue

Gets or sets a value for attributes with numeric types (Cost, Number).

public decimal NumericValue { get; set; }

Property Value

decimal

Exceptions

InvalidOperationException

Thrown if the Aspose.Tasks.ExtendedAttribute.AttributeDefinition property is not initialized or custom field type of Aspose.Tasks.ExtendedAttribute.AttributeDefinition property is not ‘Cost’ or ‘Number’.

TextValue

Gets or sets a value for attributes with ‘Text’ type.

public string TextValue { get; set; }

Property Value

string

Exceptions

InvalidOperationException

Thrown if the Aspose.Tasks.ExtendedAttribute.AttributeDefinition property is not initialized or current attribute is not a text attribute.

ValueGuid

Gets the guid of a lookup value.

public string ValueGuid { get; }

Property Value

string

Remarks

Should not be set directly, instead use ExtendedAttributeDefinition.CreateExtendedAttribute(Value lookupValue) to create an extended attribute with a lookup value.

ValueReadOnly

Gets a value indicating whether a value of this Aspose.Tasks.ExtendedAttribute instance is read-only. returns true if a formula or rollup is defined in the Aspose.Tasks.ExtendedAttributeDefinition for this object.

public bool ValueReadOnly { get; }

Property Value

bool

Methods

ToString()

Returns short string representation of an extended attribute.

public override string ToString()

Returns

string

The string representation of the extended attribute.