Hi @Cenk ,
I am working on an ASP.NET Core Blazor Server app. I have Orders and Order Details data in SQL Server. I would like to export this master-detail relationship to excel. Any ideas on how can I manage this? (By the way, I am using Epplus for uploading excel in my application.)
Since you re using Epplus to upload the excel, you can also use the Epplus to export the data to an excel file.
You can create a Razor page in the Pages folder, and add the following code: 222932-sourcecode.txt
Then, in the Blazor component, add the download hyperlink:
<a class="btn btn-primary" href="/download">Export to Excel</a>
After clicking the hyperlink, the excel file as below:
Besides, you can also refer to my reply in this thread, and use client side package or OpenXML to export to excel.
If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.
Best regards,
Dillion