FAQ Database Discussion Community


Easiest method to OrderBy a String using StringComparison.Ordinal

c#,string,compare,ienumerable,ordinal
I've found a bug (in my code) that results from String.CompareTo and binary search because my custom IComparer (for the wrapping type) uses String.Compare(x, y, StringComparison.Ordinal). This is because items.OrderBy(i => i.Name) (where Name is of type string) used to build the Array to search used the string object itself...

How to make a Highstocks x-axis even and regular?

javascript,highcharts,ordinal
I am using the highstocks library for JavaScript to render some data collected as part of a school project. While highstocks has proven great, the x-axis is acting up. Due to interference, the collected data does not always come with neat intervals, and I would like the graph to reflect...