Nevron Forum
Back
Login
Register
Login
Register
Home
»
Nevron Vision for NET
»
Nevron Chart for .NET
»
Time format changes on publish
Time format changes on publish
Post Reply
Time format changes on publish
View
Flat Ascending
Flat Descending
Threaded
Options
Subscribe to topic
Print This Topic
Goto Topics Forum
Author
Message
Mike O'Ceirin
Mike O'Ceirin
posted 5 Years Ago
ANSWER
Topic Details
Group: Forum Members
Posts: 22,
Visits: 184
My solution produces a chart with the x-axis being in 24-hour time. That is I have 21:00 22:00 et cetera this works well on my development machine. When I publish to the Web server the times changed to am/pm so that is 9:00 pm 10:00 pm and so on. I surmise the chart is reading it from the computer it is running on. I doubt I can change that so how do I force the NEVRON chart to write 24-hour time? It is ASP.NET using a web form.
I have tried using
dateTimeScale.LabelValueFormatter = new NDateTimeValueFormatter("HH:mm");
but it makes no difference.
Reply
Like
0
Reply
Nevron Support
Nevron Support
posted 5 Years Ago
ANSWER
Post Details
Group: Administrators
Posts: 3.1K,
Visits: 4.2K
Hi Mike,
You're correct - the control uses the current machine (server) culture settings for label formatting. To override this behavior you can use:
NDateTimeScaleConfigurator dateTimeScale = new NDateTimeScaleConfigurator();
dateTimeScale.EnableUnitSensitiveFormatting = false;
NDateTimeValueFormatter labelFormatter = new NDateTimeValueFormatter("HH:mm");
labelFormatter.CultureInfo = CultureInfo.InvariantCulture;
dateTimeScale.LabelValueFormatter = labelFormatter;
This will ensure that you always use the same culture settings regardless of the server.
We hope this helps - let us know if you meet any problems or have any questions.
Best Regards,
Nevron Support Team
Reply
Like
0
GO
Merge Selected
Merge into selected topic...
Merge into merge target...
Merge into a specific topic ID...
Open Merge
Threaded View
Threaded View
Time format changes on publish
Mike O'Ceirin
-
5 Years Ago
Hi Mike, You're correct - the control uses the current machine...
Nevron Support
-
5 Years Ago
Spot on thank you. I have a lot of time looking at your documentation...
Mike O'Ceirin
-
5 Years Ago
Hi Mike, We don't' have a shortened version of the user’s guide,...
Nevron Support
-
5 Years Ago
Post Reply
Similar Topics
Post Quoted Reply
Reading This Topic
Login
Login
Remember Me
Reset Password
Resend Validation Email
Login
Explore
Messages
Mentions
Search