@ref="CandleChart"
UseGroupingSeparator="true"
EnableCanvas="true"
SelectionMode="SelectionMode.Point"
Height="100%"
Width="100%"
EnableAnimation="false">
ValueType="Syncfusion.Blazor.Charts.ValueType.DateTime">
Enable="true" />
Width="0" />
DataSource="@ChartData"
Name="TrainingData"
BearFillColor="#2ecd71"
BullFillColor="#e74c3d"
XName="@nameof(Candle.TimestampUtc)"
High="@nameof(Candle.High)"
Low="@nameof(Candle.Low)"
Open="@nameof(Candle.Open)"
Close="@nameof(Candle.Close)"
Type="ChartSeriesType.Candle">
Enable="true" />
when i debug i see that the DateTime format of TimestampUtc is MM/dd/yyyy in the debugger, when i look at my mac osx regional settings i have set it to dd.MM.yyyy as this is the locations regional setting for me.
Then i get this:
Uncaught (in promise) TypeError: Cannot read property 'replace' of undefined
at Object.u [as getResultantPattern] (syncfusion-blazor.min.js:1)
at Function.t.dateParser (syncfusion-blazor.min.js:1)
at t.getDateParser (syncfusion-blazor.min.js:1)
at t.processJsonData (charts-0a1cee.min.js:1)
at t.dataManagerSuccess (charts-0a1cee.min.js:1)
at charts-0a1cee.min.js:1
If the DateTime format in the debuuger shows dd.MM.yyyy on my windows with same regional settings it works.
if i set my mac osx reagional settings to correlate to the MM/dd/yyyy Format, i still get this error in the browser when i try to view the chart.
one more test:
on my mac i have added the following code to the methode that updates the data for the chart and then sets a StateHasChanged(), i added the following
try {
CultureInfo culture = (CultureInfo)CultureInfo.CurrentCulture.Clone();
culture.DateTimeFormat.ShortDatePattern = "dd.MM.yyyy";
culture.DateTimeFormat.LongDatePattern = "dd.MM.yyyy hh:mm:ss";
Thread.CurrentThread.CurrentCulture = culture;
}
catch(Exception exception){
}
this changes the DateTime to the format of dd.MM.yyyy this was verified by the debugger, but i still get the error in the browser as above.
my mac osx regional settings are set to dd.MM.yyyy