Range Band in Xamarin Sparkline (SfSparkline)

18 May 20211 minute to read

This feature is used to highlight a particular region in the sparkline along Y axis.

  • RangeBandStart - used to configure the start range band value in Y axis.
  • RangeBandEnd - used to configure the end range band values in Y axis.
  • RangeBandColor - used to change the color for range band.
<sparkline:SfLineSparkline ItemsSource="{Binding Data}" 
SfLineSparkline lineSparkline = new SfLineSparkline()
    YBindingPath = "Performance",
    ItemsSource = viewModel.Data,
    RangeBandStart = 4000,
    RangeBandEnd = 1000,
    RangeBandColor = Color.FromRgba(0, 255, 0, 100)

Range band support in Xamarin.Forms Sparkline