Pre loader

Cusomize Grids and Grid lines and Grid Bands

Welcome to the SciChart Forums!

  • Please read our Question Asking Guidelines for how to format a good question
  • Some reputation is required to post answers. Get up-voted to avoid the spam filter!
  • We welcome community answers and upvotes. Every Q&A improves SciChart for everyone

WPF Forums | JavaScript Forums | Android Forums | iOS Forums

0
0

Hi ,

I am trying to change background color of scichart surface and also need to change color of grid bands and grid lines.

So far I am able change background color of scichart surface using scichartSurface.setBackgroundcolor API

But I am not able to find api can customize/ remove grid bands and grid lines.

Please find images attached for more details.

Version
2.0.1.884
Images
  • You must to post comments
0
0

Hi there,

You can remove bands/gridlines by calling setDrawMajorGridlines, setDrawMinorGridlines and setDrawMajorBands with false flag for your X and Y axes:

xAxis.setDrawMajorGridLines(false);
xAxis.setDrawMinorGridLines(false);
xAxis.setDrawMajorBands(false);

yAxis.setDrawMajorGridLines(false);
yAxis.setDrawMinorGridLines(false);
yAxis.setDrawMajorBands(false);

If you need to customize bands/gridlines you need to set properties above to true to enable drawing and then set PenStyle\BrushStyle with desired colors for X and Y axes:

xAxis.setMajorGridLineStyle(majorGridlineStyle);
xAxis.setMinorGridLineStyle(minorGridlineStyle);
xAxis.setAxisBandsStyle(bandsStyle);

yAxis.setMajorGridLineStyle(majorGridlineStyle);
yAxis.setMinorGridLineStyle(minorGridlineStyle);
yAxis.setAxisBandsStyle(bandsStyle);

You can find more information about customization of axis in our documentation.

This should provide desired appeareance of chart. Hope this will help you!

Best regards,
Yura

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.

Try SciChart Today

Start a trial and discover why we are the choice
of demanding developers worldwide

Start TrialCase Studies