Muokkaa

Jaa


CollectionEditor.CollectionForm.CanRemoveInstance(Object) Method

Definition

Indicates whether you can remove the original members of the collection.

protected:
 bool CanRemoveInstance(System::Object ^ value);
protected bool CanRemoveInstance (object value);
member this.CanRemoveInstance : obj -> bool
Protected Function CanRemoveInstance (value As Object) As Boolean

Parameters

value
Object

The value to remove.

Returns

true if it is permissible to remove this value from the collection; otherwise, false. By default, this method returns the value from CanRemoveInstance(Object) of the CollectionEditor for this form.

Remarks

When implemented in a derived class, this method indicates whether the specified value can be removed from the collection. By default, this returns the value from CanRemoveInstance of the CollectionEditor for this form.

This method is called when the user tries to remove from the collection an item that is an original member of the collection. This method is not called when removing items that were added in this editing session, because they are not yet part of the collection.

Applies to