Pre loader

format a number in second since 1970.01.01 in DateTimeNumericAxis

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


In a DateTimeNumericAxis, can I convert the number from VisibleRange to a formatted string HH:MM:SS?
For example, I’d like to convert this x1 to 12/1/1984, 3:00:00 PM, or 15:00:00.

let x1 = this.parentSurface.annotations.getById("hrv").x1;
// x1 =470761200, seconds since 1970.01.01 00:00:00


  • You must to post comments

Hello, you simply want to convert the seconds into a formatted date string, right?
If I understood correctly, this is a general question about working with dates…
So here are some hints. You may use a Date object and its methods to construct whatever format you want
or alternatively, you may use a third-party library for working with dates, e.g

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.