VintaSoft Imaging .NET SDK v8.6
Vintasoft.Imaging.Annotation Namespace / AnnotationData Class / Clone Method

In This Topic
    Clone Method (AnnotationData)
    In This Topic
    Creates a new object that is a copy of the current instance.
    Public MustOverride Function Clone() As Object
    public abstract object Clone()
    public: abstract Object* Clone(); 
    abstract Object^ Clone(); 

    Return Value

    A new object that is a copy of this instance.
    This example shows how to clone one annotation from a collection and add cloned annotation into the same collection:
    Private Sub CloneAndAdd(annotationCollection As Vintasoft.Imaging.Annotation.AnnotationDataCollection, index As Integer)
        ' clone annotation at specified index
        Dim clonedAnnotation As Vintasoft.Imaging.Annotation.AnnotationData = DirectCast(annotationCollection(index).Clone(), Vintasoft.Imaging.Annotation.AnnotationData)
        ' add cloned annotation to the end of the collection
    End Sub
    void CloneAndAdd(Vintasoft.Imaging.Annotation.AnnotationDataCollection annotationCollection, int index)
        // clone annotation at specified index
        Vintasoft.Imaging.Annotation.AnnotationData clonedAnnotation = 
        // add cloned annotation to the end of the collection

    Target Platforms: Windows 10, Windows 8, Windows 7, Windows Vista, Windows XP, Windows Server 2012, Windows Server 2008, Windows Server 2003

    See Also