Hello,
I am trying to upload the stream object received from the 'ToXlsxStream' method of Telerik SpreadSheet processing library to Azure blob container. Unfortunately, it is saving as a blank excel file. I have data in the List object which is getting converted to xlsx stream. Not sure why the excel file is blank. Tried to save the stream to my local file explorer as well. Still, the issue persists.
Below is the code:
try
{
Stream exportStream = exportFormat == SpreadDocumentFormat.Xlsx ? workOrderList.ToXlsxStream(columnsData, (string)options.title.ToString(), cellStyleAction: cellStyle) : workOrderList.ToCsvStream(columnsData);
Task.Factory.StartNew(() => AzureHelper.UploadReportOnCloud(exportStream,fileName, ConfigurationManager.AppSettings[Constant.REPORTATTACHMENTCONTAINER]));
}
catch(Exception ex)
{
}
Please help me to resolve this issue.
Hello,
I have a corrupted XLSX file from CSV dataSource
With other CSV dataSource all is ok
In example in file-attach, I added CSV dataSource with corruption
There are 2 bad lines in generated XLSX file and CSV file have a good format !!!
It's not an issue with codepage or separator !
It's a projet DotNet Core 6 with last version 2023.2.713.20 of API
Do you have encountered this error already ?
Best regards
Cyril REILER
Hi all,
I got some problems when I try to read my Excel file as below:
1. It skipped the null cells, it only read data at the cells having value. For example in my case, after reading cell 2 at row 2, it jumped to cell 14.
2. It showed the error message "The given key '3' was not present in the dictionary." at cell 15
You can see my code, the Excel file I used, and the result in below
My code
@page "/testpage"
@using Telerik.Documents.SpreadsheetStreaming;
<div>
@((MarkupString)(str.ToString()))
</div>
@code {
private StringBuilder str = new StringBuilder();
protected override void OnInitialized()
{
str = ReadData();
}
private StringBuilder ReadData()
{
try
{
string filename = ".\\Template.xlsx";
using (FileStream fs = new FileStream(filename, FileMode.Open))
{
using (IWorkbookImporter workBookImporter = SpreadImporter.CreateWorkbookImporter(SpreadDocumentFormat.Xlsx, fs))
{
foreach (IWorksheetImporter worksheetImporter in workBookImporter.WorksheetImporters)
{
foreach (IRowImporter rowImporter in worksheetImporter.Rows)
{
foreach (ICellImporter cell in rowImporter.Cells)
{
if(cell.Value!= null)
{
str.Append(cell.Value.ToString());
}
else
{
str.Append("NULL");
}
str.Append(",");
}
str.Append("<br/>");
}
}
}
}
return str;
}
catch(Exception ex)
{
str.Append("<br/>");
str.Append(ex.Message);
return str;
}
}
}
My Excel file as a picture below, I also attached my Excel in the question (Template.rar)
The result when I run
Everyone who know how to fix it, please help me.
Thank you
I need to rotate the text vertically.
It seems the TextRotation is unavailable when using Telerik.Documents.SpreadsheetStreaming.SpreadCellStyle.
How do I apply text rotation to a style using SpreadsheetStreaming?
Thanks,
Jim
Hello All,
I am using Telerik.Documents.SpreadsheetStreaming assembly with Version 2020.3.1019.20. I just need how to assign text having hyperlink to ICellExporter object here. Please suggest me if there is any wrong here.
string policy = "<a href=\"https://www.termsfeed.com/blog/sample-terms-and-conditions-template/\">Policy Terms</a>";
string showText = "For necessary info, Please refer " + policy;
//rowExporter -> IRowExporter object here
using var cellExporter = rowExporter.CreateCellExporter();
cellExporter.SetValue(showText);
Thanks
Sam
Hi,
I'm using IWorksheetExporter (Telerik.Documents.SpreadsheetStreaming library) to create big Excel files, ~400 mb xlsx.
I need to add notes to header cells like what is available here https://docs.telerik.com/devtools/document-processing/libraries/radspreadprocessing/features/notes but it doesn't look to be available in the Streaming library.
I see two possible workarounds.
NB. Trying to completely create this file via the RadSpreadProcessing library throw a "Stream was too long" from within the library while saving it.
NB. I'm using the latest version from the nuget stream.
Thanks
Hello All,
I am using the RadSpreadStreamProcessing to export data to an Excel spreadsheet and I would like to know how to declare the column headers in the exported spreadsheet as Sortable/Filterable? Is there an example that I can be pointed to?
Thanks for any help you can provide.
W
Hi all I have a problem during the import of an existing excel file with formula inside
(e.c. IF(H1<>"";IF(J1="";"";INDEX(INDIRECT(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE("Var_"&C1&"_"&G1&"_"&H1;" ";"hex20");"-";"hex2d");"(";"hex28");")";"hex29");"/";"hex2f");"+";"hex2b");"&";"hex26");".";"hex2e")&"_Daily");MATCH(J1;INDIRECT(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE(SUBSTITUTE("Var_"&C1&"_"&G1&"_"&H1;" ";"hex20");"-";"hex2d");"(";"hex28");")";"hex29");"/";"hex2f");"+";"hex2b");"&";"hex26");".";"hex2e")&"_Levels");0)));""
or
==EOMONTH(startdate;-1)
These formula are used in different cells in different sheets and when I try to bind the generated json to a spreadsheet component I received this error:
As posted in some forum It seems due to the culture used during excel generation (I tried different approach: attached a different culture to the current thread server side, force kendo core library to use a specific culture client side, force spreadsheet to use a specific culture server side).
How can I resolved this issue?
I did not found any working solution on line.
Thank you in advanced
Eleonora
Used with Blazor, anyway we can get rid of this warning?
Telerik.Documents.SpreadsheetStreaming 2022.2.613 requires Telerik.Zip (= 2022.2.613) but version Telerik.Zip 2022.3.906 was resolved
Are there any plans of making async functions in RadSpreadStreamProcessing?
When used in a server environment, that would increase throughput of requests a lot...