Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

RepositoryItemMRUEdit.AddingMRUItem Event

Occurs before an item is added to the MRU editor.

Namespace: DevExpress.XtraEditors.Repository

Assembly: DevExpress.XtraEditors.v24.2.dll

NuGet Package: DevExpress.Win.Navigation

#Declaration

[DXCategory("Events")]
public event AddingMRUItemEventHandler AddingMRUItem

#Event Data

The AddingMRUItem event's data class is AddingMRUItemEventArgs. The following properties provide information specific to this event:

Property Description
AddReason Gets the reason that caused the AddingMRUItem event.
Cancel Gets or sets a value indicating whether the event should be canceled. Inherited from CancelEventArgs.

#Remarks

The AddingMRUItem event is raised before an item is added to the RepositoryItemMRUEdit.Items collection of a MRU editor. You can provide an event handler for this event to perform actions when adding a new item. For instance, you can examine the item for validity and cancel if the item does not meet requirements.

The AddingMRUItem event provides an argument of the AddingMRUItemEventArgs type. Use properties exposed by this argument to obtain the new item and to cancel the operation, if necessary.

A MRU editor’s MRUEdit.AddingMRUItem event is an equivalent of the current event.

See Also