Edit

Bagikan melalui


XmlStreamStore.AddAnnotation(Annotation) Method

Definition

Adds a new Annotation to the store.

public:
 override void AddAnnotation(System::Windows::Annotations::Annotation ^ newAnnotation);
public override void AddAnnotation (System.Windows.Annotations.Annotation newAnnotation);
override this.AddAnnotation : System.Windows.Annotations.Annotation -> unit
Public Overrides Sub AddAnnotation (newAnnotation As Annotation)

Parameters

newAnnotation
Annotation

The annotation to add to the store.

Exceptions

newAnnotation is null.

An Annotation with the same Id already is in the store.

An I/O Stream has not been set for the store.

Dispose has been called on the store.

Remarks

When AddAnnotation is called, the Id of the Annotation is checked to see whether the Annotation already has been added to the store. If the Annotation already has been added and is in the store an ArgumentException error is thrown.

Applies to

See also