New to Telerik Document ProcessingStart a free 30-day trial

Base collection for managing options in choice fields; add, remove, index, and enumerate items.

Definition

Namespace:Telerik.Windows.Documents.Fixed.Model.InteractiveForms

Assembly:Telerik.Windows.Documents.Fixed.dll

Type Parameters:

T

The type of field option that extends FieldOptionBase.

Syntax:

C#
public class FieldOptionCollection<T> : IEnumerable<T>, IEnumerable where T : FieldOptionBase

Inheritance: objectFieldOptionCollection<T>

Derived Classes: ChoiceOptionCollectionRadioOptionCollection

Implements: IEnumerableIEnumerable<T>

Methods

Add an option to the end of the collection.

C#
public void Add(T option)
Parameters:optionT

The option.

Remove all options from the collection.

C#
public void Clear()

Return an enumerator that iterates through the options.

C#
public IEnumerator<T> GetEnumerator()
Returns:

IEnumerator<T>

The options.

Implements: IEnumerable<T>.GetEnumerator()

Remove the option at the specified index.

C#
public void RemoveAt(int index)
Parameters:indexint

The option index.

Properties

The total number of options in the collection.

C#
public int Count { get; }
Property Value:

The number of options in the collection.

Get or set the option at the specified index.

C#
public T this[int index] { get; set; }
Parameters:indexint

The zero-based index of the option to get or set.

Property Value:

The field option at the specified index.

Exceptions:

ArgumentOutOfRangeException

Thrown when the index is outside the bounds of the collection.

ArgumentNullException

Thrown when attempting to set a null value.