ChartControl.AnnotationRepositoryChanged Event
Occurs after a user adds, edits or deletes an annotation.
Namespace: DevExpress.XtraCharts
Assembly: DevExpress.XtraCharts.v24.2.UI.dll
Declaration
Event Data
The AnnotationRepositoryChanged event's data class is AnnotationRepositoryChangedEventArgs. The following properties provide information specific to this event:
Property | Description |
---|---|
Annotation | Returns the changed annotation. |
Change | Returns the AnnotationRepositoryChange value that indicates the type of change a user makes. |
Remarks
Users can utilize the Add Text Annotation and Add Image Annotation buttons in the Chart’s Ribbon or Toolbars to add interactive annotations. They can also edit or delete an annotation if the Annotation.RuntimeEditing property is set to true.
The e.Change property returns an operation that a user performs. The Change property can be set to the following values:
The e.Annotation property returns the changed annotation.
The following example gets a type of the annotation change and the annotation object:
void chartControl1_AnnotationRepositoryChanged(object sender, AnnotationRepositoryChangedEventArgs e) {
AnnotationRepositoryChange lastChange = e.Change;
Annotation myAnnotation = e.Annotation;
//Add your logic here.
}