diff --git a/Microsoft.Toolkit.Uwp.SampleApp/Data/DataGridDataSource.cs b/Microsoft.Toolkit.Uwp.SampleApp/Data/DataGridDataSource.cs index 688b17292..392542171 100644 --- a/Microsoft.Toolkit.Uwp.SampleApp/Data/DataGridDataSource.cs +++ b/Microsoft.Toolkit.Uwp.SampleApp/Data/DataGridDataSource.cs @@ -5,6 +5,7 @@ using System; using System.Collections.Generic; using System.Collections.ObjectModel; +using System.Globalization; using System.IO; using System.Linq; using System.Text; @@ -30,6 +31,7 @@ namespace Microsoft.Toolkit.Uwp.SampleApp.Data StorageFile file = await StorageFile.GetFileFromApplicationUriAsync(uri); IRandomAccessStreamWithContentType randomStream = await file.OpenReadAsync(); _items = new ObservableCollection(); + IFormatProvider provider = CultureInfo.InvariantCulture.DateTimeFormat; using (StreamReader sr = new StreamReader(randomStream.AsStreamForRead())) { @@ -48,7 +50,7 @@ namespace Microsoft.Toolkit.Uwp.SampleApp.Data Coordinates = values[4], Prominence = uint.Parse(values[5]), Parent_mountain = values[6], - First_ascent = DateTimeOffset.Parse(values[7]), + First_ascent = DateTimeOffset.Parse(values[7], provider), Ascents = values[8], }); }