Base List ControlObject CollectionInsert Method
Insert a value into the collection at the specified index
Definition
Namespace: EWSoftware.ListControls
Assembly: EWSoftware.ListControls (in EWSoftware.ListControls.dll) Version: 2024.12.31.0
Assembly: EWSoftware.ListControls (in EWSoftware.ListControls.dll) Version: 2024.12.31.0
C#
public void Insert(
int index,
Object? value
)VB
Public Sub Insert (
index As Integer,
value As Object
)C++
public:
virtual void Insert(
int index,
Object^ value
) sealedF#
abstract Insert :
index : int *
value : Object -> unit
override Insert :
index : int *
value : Object -> unit Parameters
Implements
IListInsert(Int32, Object)Remarks
If the collection is sorted, the value is added to the collection and the collection is
resorted. The value may or may not end up at the requested index.
Exceptions
| ArgumentNullException | This is thrown if the value is null. |
| ArgumentOutOfRangeException | This is thrown if the index value is not within the bounds of the collection. |
| ArgumentException | This is thrown if an attempt is made to add a value to the collection when a data source is in use. |