Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
34510
Using DateTimeCategoryXAxis with ValueOverlay
posted

How do I use the ValueOverlay along with the DateTimeCategoryXAxis in the XamDataChart?

The ValueOverlay currently only works with numerical values.  It is not possible to feed it a DateTime object so in order to make this work we'll need to create our own version of the ValueOverlay that will support DateTime.  The good thing is that ValueOverlay is just a type of series so it's relatively simple to create our own.

I've attached a sample that does just that.  It creates a new overlay called DateTimeValueOverlay that behaves similarly to ValueOverlay.

WpfApplication1.zip