Profile Picture

Duplicate dates for 12-hour intervals in charts

Posted By Ronnie Cohen 11 Years Ago
Author
Message
Ronnie Cohen
Posted 11 Years Ago
View Quick Profile
Forum Newbie

Forum Newbie (7 reputation)Forum Newbie (7 reputation)Forum Newbie (7 reputation)Forum Newbie (7 reputation)Forum Newbie (7 reputation)Forum Newbie (7 reputation)Forum Newbie (7 reputation)Forum Newbie (7 reputation)Forum Newbie (7 reputation)

Group: Forum Members
Last Active: 10 Years Ago
Posts: 7, Visits: 1
We can see in the chart part, on x-axis, the date displays duplicates (see attached image). This is confusing on the GUI for users.
In grid, dataset looks fine and there is no duplicate date.

By showing the data point, we understand for example the first 01-01-2011 is for 00:00, and the second 01-01-2011 is for 12:00.

This may be caused by a Nevron setting that is using 12 hours instead of 24 hours. What Nevron object needs to be changed and how can it be changed to use 24 hours rather than 12 hours?

I need to remove the duplicate dates on the x-axis or show the times next to the dates when 12-hour intervals are used.

Attachments
Nevron Support
Posted 11 Years Ago
View Quick Profile
Supreme Being

Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)

Group: Forum Members
Last Active: Yesterday @ 1:54 AM
Posts: 3,054, Visits: 4,009

Hi Ronnie,

Can you post the code you use to configure the axis? - this result can be caused if you use fixed date time formatting which is not suitable for the current step determined by the axis. In other words you probably specified day / month / year formatting, but the step uses half day step (as it is probably automatically computed), which results in two equal labels on the axis.



Best Regards,
Nevron Support Team



Ronnie Cohen
Posted 11 Years Ago
View Quick Profile
Forum Newbie

Forum Newbie (7 reputation)Forum Newbie (7 reputation)Forum Newbie (7 reputation)Forum Newbie (7 reputation)Forum Newbie (7 reputation)Forum Newbie (7 reputation)Forum Newbie (7 reputation)Forum Newbie (7 reputation)Forum Newbie (7 reputation)

Group: Forum Members
Last Active: 10 Years Ago
Posts: 7, Visits: 1
Here is the source code that is used for datetime scaling:

Private _DateTimeScaleConfigurator As NDateTimeScaleConfigurator
_DateTimeScaleConfigurator = New NDateTimeScaleConfigurator()
_DateTimeScaleConfigurator.MajorGridStyle.SetShowAtWall(ChartWallType.Back, True)
_DateTimeScaleConfigurator.MajorGridStyle.LineStyle.Pattern = LinePattern.DashDot
_DateTimeScaleConfigurator.EnableUnitSensitiveFormatting = False
_DateTimeScaleConfigurator.EnableUnitSensitiveFormatting = True

CartesianChart.Axis(StandardAxis.PrimaryX).ScaleConfigurator = _DateTimeScaleConfigurator

'NOTE: CartesianChart is an NCartesianChart object.


Nevron Support
Posted 11 Years Ago
View Quick Profile
Supreme Being

Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)

Group: Forum Members
Last Active: Yesterday @ 1:54 AM
Posts: 3,054, Visits: 4,009

Hi Ronnie,

You probably need to modify the format for half day unit:

_DateTimeScaleConfigurator.DateTimeUnitFormatterPairs.HalfDayFormatter.FormatSpecifier = "SomeNewFormat";

For example "yy MM dd tt" - for year, month, day followed by AM/PM depending on the part of day. Also it does not make sense to turn off and then off the unit sensitive formatting:

_DateTimeScaleConfigurator.EnableUnitSensitiveFormatting = False
_DateTimeScaleConfigurator.EnableUnitSensitiveFormatting = True

You should leave only the last line...



Best Regards,
Nevron Support Team





Similar Topics


Reading This Topic