ActiveReports 12
Annotation Class
Members  Example 

GrapeCity.ActiveReports.Document.v12 Assembly > GrapeCity.ActiveReports.Document.Section.Annotations Namespace : Annotation Class
Annotation is the base class for Annotation objects.
Object Model
Annotation Class
Syntax
'Declaration
 
Public Class Annotation 
   Inherits System.ComponentModel.Component
public class Annotation : System.ComponentModel.Component 
Example
using GrapeCity.ActiveReports.Document.Section.Annotations;

rptAnnotations rpt = new rptAnnotations();
private void AddAnnotations()
{
   //Run the report first
   rpt.Run();
   
   //Assign the viewer
   this.viewer1.Document = rpt.Document;
   
   //Create an annotation and assign property values
   AnnotationCircle circle = new AnnotationCircle();
   circle.Color = System.Drawing.Color.GreenYellow;
   circle.Border.Color = System.Drawing.Color.Chartreuse;
  
   //Add the annotation
   circle.Attach(1,1); //screen location
   this.viewer1.Document.Pages[0].Annotations.Add(circle);

   //Set the size properties. The annotation must be added to the page first.
   circle.Height = 0.25f;
   circle.Width = 0.50f;

   //Save annotations to an RDF file
   rpt.Document.Save("C:\\MyAnnotations.rdf");
}
Dim rpt As New rptAnnotations
Private Sub AddAnnotations() 
   'Run the report first
   rpt.Run()

   'Assign the viewer
   Me.Viewer1.Document = rpt.Document

   'Create an annotation and assign property values
   Dim circle As New AnnotationCircle
   circle.Color = System.Drawing.Color.GreenYellow
   circle.Border.Color = System.Drawing.Color.Chartreuse

   'Add the annotation
   circle.Attach(1,1) 'screen location
   Me.Viewer1.Document.Pages(0).Annotations.Add(circle)

   'Set the size properties. The annotation must be added to the page first.
   circle.Height = 0.25
   circle.Width = 0.50

   'Save annotations to an RDF file
   rpt.Document.Save("C:\\MyAnnotations.rdf")
End Sub
Inheritance Hierarchy

System.Object
   System.MarshalByRefObject
      System.ComponentModel.Component
         GrapeCity.ActiveReports.Document.Section.Annotations.Annotation
            GrapeCity.ActiveReports.Document.Section.Annotations.AnnotationBaseText
            GrapeCity.ActiveReports.Document.Section.Annotations.AnnotationCircle
            GrapeCity.ActiveReports.Document.Section.Annotations.AnnotationLine
            GrapeCity.ActiveReports.Document.Section.Annotations.AnnotationRectangle

See Also

Reference

Annotation Members
GrapeCity.ActiveReports.Document.Section.Annotations Namespace