Class RemovingFromListEventArgs
- Namespace
- CADability
- Assembly
- CADability.dll
Used as a parameter in the event RemovingFromListDelegate. When handling an appropriate event, you can prevent the object beeing removed from the list.
public class RemovingFromListEventArgs : EventArgs
- Inheritance
-
RemovingFromListEventArgs
- Inherited Members
Constructors
RemovingFromListEventArgs(object, object, string, string)
Creates an RemovingFromListEventArgs object.
public RemovingFromListEventArgs(object List, object Item, string Name, string ResourceID)
Parameters
ListobjectThe List, from which the object is going to be removed
ItemobjectThe object that is going to be removed
NamestringName of the item
ResourceIDstringResource ID for the messages displayed in ItemIsUsed()
Fields
Item
The object that is going to be removed.
public object Item
Field Value
List
The list from which the object is going to be removed.
public object List
Field Value
Name
Name of the Item.
public string Name
Field Value
Refuse
Set this to true if you want to prevent the object to be removed.
public bool Refuse
Field Value
ResourceID
Resource ID for errormessages that will be displayed in ItemIsUsed(). ResourceID+".ItemIsUsed" is the formattable string like "Item with the name {0} is used. Do you want to remove it anyway". ResourceID+".Label" is used for the Title of the message.
public string ResourceID
Field Value
Methods
DontRemoveLastItem()
Displays a massage telling the user that the last item cannot be removed
public virtual void DontRemoveLastItem()
ItemIsUsed()
Displays a massage telling the user that the item is still in use and asks the user whether the item should be removed anyway.
public virtual void ItemIsUsed()