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.


I am using a SciStockChart and trying to add Trade Markers as outlined here However, I am not getting a proper xCoordinate from the coordinate calculator. I believe SciStockChart is using a CategoryCoordinateCalculator and I must do an extra step in order to get the proper result from the DateTime input. Here is the line that is not working correctly. double xCoord = xCoordCalculator.GetCoordinate(trade.ExecutionTime.Value); Is there another step I need to take in order to get the proper xCoord value?

  • You must to post comments

ok, I seem to have solved this. I’m casting the current x coordinate calculator to a category calculator like this.
var xCoordCalculator = PriceChart.XAxis.GetCurrentCoordinateCalculator() as ICategoryCoordinateCalculator;

Then I get the index of the DateTime object and use the index as input to the coordinate calculator.
var index = xCoordCalculator.TransformDataToIndex(trade.ExecutionTime.Value);
double xCoord = xCoordCalculator.GetCoordinate(index);

This is working for me.

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.