SciChart® the market leader in Fast WPF Charts, WPF 3D Charts, and now iOS Charting & Android Chart Components

Welcome to the SciChart Community Forums!

Please use the forums below to ask questions about SciChart. Take a moment to read our Question asking guidelines on how to ask a good question and our support policy. We also have a tag=SciChart on where you can earn rep for your questions!

Please note: SciChart team will only answer questions from customers with active support subscriptions. Expired support questions will be ignored. If your support status shows incorrectly, contact us and we will be glad to help.


Hi, SciChart team.
Our users can add many VerticalLineAnnotations to chart. Also they need to know what annotation is active. It is usefull for annotation removing for example.

What way schould I use for change visual style for selected annotation. By default selected annotation do not differ with not selected.

At this time I am modify AddAdorners RemoveAdorners(I am use MyCustom Annotaion inherited from VerticalLineAnnotation). And use different colors. But names of theese methods confuse me.

May be it is good idea to add methods like MakeSelected and MakeUnselected. Documentation in chm file is not helpfull for this situation.

  • You must to post comments

Hi there,

You could use Triggers or Binding to achieve this, e.g.:

        <Style x:Key="VerticalLineAnnotationStyle" TargetType="s:VerticalLineAnnotation">
            <Setter Property="Stroke" Value="#FFFF6600" />
            <Setter Property="StrokeThickness" Value="2" />
            <Setter Property="ShowLabel" Value="True" />
            <Setter Property="LabelPlacement" Value="Axis" />
            <Setter Property="VerticalAlignment" Value="Stretch" />
                <Trigger Property="IsSelected" Value="True">
                    <Setter Property="Stroke" Value="Blue" />

This can be done from code too. Please, let us know if this solution is suitable for you or if you need any assistance!

Best regards,

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.