DisplayFieldList.Add Method (FieldDefinition)
Adds a FieldDefinition object to this collection at the next available index.
Namespace: Microsoft.TeamFoundation.WorkItemTracking.Client
Assembly: Microsoft.TeamFoundation.WorkItemTracking.Client (in Microsoft.TeamFoundation.WorkItemTracking.Client.dll)
Syntax
'Declaração
Public Function Add ( _
value As FieldDefinition _
) As Integer
public int Add(
FieldDefinition value
)
public:
int Add(
FieldDefinition^ value
)
member Add :
value:FieldDefinition -> int
public function Add(
value : FieldDefinition
) : int
Parameters
- value
Type: Microsoft.TeamFoundation.WorkItemTracking.Client.FieldDefinition
The FieldDefinition object to add to this collection.
Return Value
Type: System.Int32
The index in this collection of the FieldDefinition object that is added by this method.
Exceptions
Exception | Condition |
---|---|
ArgumentNullException | The argument was null. |
Remarks
This method determines whether the specified FieldDefinition is already located in this collection by checking for Id. If the specified FieldDefinition is located in this collection, its index is returned. Otherwise, the specified FieldDefinition is added to this collection and the new index is returned.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.