Members  Example 
LineAnnotation Class
Defines a read-only or editable Line annotation, which may be placed on the chart at specific X1,Y1,X2,Y2 coordinates
Object Model
LineAnnotation ClassIAnnotationCanvas InterfaceIAnnotationCanvas InterfaceIChartModifierSurface InterfaceAnnotationBase ClassIAnnotationCanvas InterfaceIAnnotationCanvas InterfaceIChartModifierSurface InterfaceAnnotationBase ClassISciChartSurface InterfaceIMainGrid InterfaceAnnotationCoordinates StructureIServiceContainer InterfaceIAxis InterfaceIAxis InterfaceISciChartSurface InterfaceIAnnotationCanvas InterfaceAnnotationCollection ClassIAnnotation InterfaceIAnnotationCanvas InterfaceIChartModifier InterfaceIGridLinesPanel InterfaceIChartModifierSurface InterfaceIRenderSurface InterfaceIMainGrid InterfaceIServiceContainer InterfaceIViewportManager InterfaceAxisCollection ClassIAxis InterfaceIAxis InterfaceAxisCollection ClassIAxis InterfaceIAxis InterfaceIZoomHistoryManager InterfaceIMainGrid InterfaceAnnotationCoordinates StructureIServiceContainer InterfaceIAxis InterfaceIRange InterfaceIRange InterfaceILabelProvider InterfaceIAnnotationCanvas InterfaceISciChartSurfaceBase InterfaceIServiceContainer InterfaceITickProvider InterfaceIRange InterfaceIRange InterfaceIAxis InterfaceIRange InterfaceIRange InterfaceILabelProvider InterfaceIAnnotationCanvas InterfaceISciChartSurfaceBase InterfaceIServiceContainer InterfaceITickProvider InterfaceIRange InterfaceIRange Interface
Syntax
[TemplatePart(Name="PART_LineAnnotationRoot", Type=System.Windows.Controls.Grid)]
[AbtLicenseProvider(SciChart.Charting.Licensing.AnnotationAbtLicenseProvider)]
[DefaultProperty("Content")]
[ContentProperty("Content")]
[Localizability(LocalizationCategory.None, Readability=Readability.Unreadable)]
[StyleTypedProperty(Property="FocusVisualStyle", StyleTargetType=System.Windows.Controls.Control)]
[XmlLangProperty("Language")]
[UsableDuringInitialization(true)]
[RuntimeNameProperty("Name")]
[UidProperty("Uid")]
[TypeDescriptionProvider(MS.Internal.ComponentModel.DependencyObjectProvider)]
[NameScopeProperty("NameScope", System.Windows.NameScope)]
public class LineAnnotation : LineAnnotationBase, IAnnotation, SciChart.Core.Framework.IHitTestable, SciChart.Core.Framework.ISuspendable  
Example
Shows how to create and add a LineAnnotation to a SciChartSurface in XAMLShows how to create and add a LineAnnotation to a SciChartSurface in Code
<!-- where xmlns:s="http://schemas.abtsoftware.co.uk/scichart"-->
<s:SciChartSurface>
   <!-- RenderableSeries omitted for brevity -->
            
   <s:SciChartSurface.XAxis>
      <s:NumericAxis Id="DefaultAxisId"/>
   </s:SciChartSurface.XAxis> 
   <s:SciChartSurface.YAxis>
      <s:NumericAxis Id="DefaultAxisId"/>
   </s:SciChartSurface.YAxis>
            
   <s:SciChartSurface.Annotations>
      <!-- Declare a LineAnnotation at X1,X2,Y1,Y2 -->
      <!-- NOTE: XAxisId and YAxisId are optional if you use default Ids on a single X,Y Axis -->
      <s:LineAnnotation X1="1" X2="2" Y1="3" Y2="4" 
                        Stroke="Orange" StrokeThickness="2" StrokeDashArray="2 2"
                        AnnotationCanvas="AboveChart"
                        IsSelected="False"
                        IsEditable="False"
                        XAxisId="DefaultAxisId"
                        YAxisId="DefaultAxisId" />
   </s:SciChartSurface.Annotations>
</s:SciChartSurface>
var sciChartSurface = new SciChartSurface();
sciChartSurface.XAxis = new NumericAxis() { Id = "DefaultAxisId" };
sciChartSurface.YAxis = new NumericAxis() { Id = "DefaultAxisId" };
            
// Declare a LineAnnotation at X1,X2,Y1,Y2
// NOTE: XAxisId and YAxisId are optional if you use default Ids on a single X,Y Axis
sciChartSurface.Annotations.Add(new LineAnnotation() 
{
   X1 = 1, X2 = 2, Y1 = 3, Y2 = 4, 
   Stroke = new SolidColorBrush(Colors.Orange), 
   StrokeThickness = 2, 
   StrokeDashArray = new DoubleCollection(new double[] { 2, 2 }),
   AnnotationCanvas = AnnotationCanvas.AboveChart, 
   IsSelected = false, 
   IsEditable = false, 
   XAxisId = "DefaultAxisId", 
   YAxisId = "DefaultAxisId",
});
Inheritance Hierarchy

System.Object
   System.Windows.Threading.DispatcherObject
      System.Windows.DependencyObject
         System.Windows.Media.Visual
            System.Windows.UIElement
               System.Windows.FrameworkElement
                  System.Windows.Controls.Control
                     System.Windows.Controls.ContentControl
                        SciChart.Charting.ChartModifiers.ApiElementBase
                           SciChart.Charting.Visuals.Annotations.AnnotationBase
                              SciChart.Charting.Visuals.Annotations.LineAnnotationBase
                                 SciChart.Charting.Visuals.Annotations.LineAnnotation
                                    SciChart.Charting.DrawingTools.TradingAnnotations.ExtendedLineAnnotation
                                    SciChart.Charting.DrawingTools.TradingAnnotations.FibonacciAnnotation.FibonacciRatioLineBase
                                    SciChart.Charting.Visuals.Annotations.CustomLineAnnotation
                                    SciChart.Charting.Visuals.Annotations.LineAnnotationForMvvm
                                    SciChart.Charting.Visuals.Annotations.LineAnnotationWithLabelsBase
                                    SciChart.Charting.Visuals.Annotations.TrendLineAnnotationBase

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also