To reproduce:
CultureInfo cultureInfo = new CultureInfo("es-ES");Importing XLSX file in Blazor Web Assembly for .NET 5.0 is very slow.
<InputFile OnChange="@HandleFileSelected" />
async Task HandleFileSelected(InputFileChangeEventArgs e)
{
var ms = new MemoryStream((int)e.File.Size);
Telerik.Windows.Documents.Spreadsheet.FormatProviders.OpenXml.Xlsx.XlsxFormatProvider formatProvider = new Telerik.Windows.Documents.Spreadsheet.FormatProviders.OpenXml.Xlsx.XlsxFormatProvider();
using (Stream ey = e.File.OpenReadStream(e.File.Size))
{
await ey.CopyToAsync(ms,(int)e.File.Size);
ey.Close();
}
oWorkbook = formatProvider.Import(ms);
}
When the column has cells that span several rows, the auto fit of column width is not working.
Workaround: If the document is being generated with the API, autofit the contents before merging the data.
The files are not properly recognized when the base64 string representing the exported XLS file is converted using https://base64.guru/converter/decode/file.
If an XLS file produced by MS Excel is converted with the same tool, it is generated with .bin extension.
The content of some rows which contain new lines can be clipped when a fixed-width column is wrapped.
This can be observed in the following images.
Before the export:
After the export:
The vertical grid lines are not visible in a scatter chart. The grid lines are visible when opened in Excel.