I have a nested collection and I want the parent columns to be merged. So I use ;merge after parent column names and they merge but the cell value is not vertically centered as was in cell of template document. Merged cell values is always vertically top.
One more thing, the ;merge doesnt work with ;insert:copystyles,copymerges
|
using (ExcelEngine excelEngine = new ExcelEngine())
{
IApplication application = excelEngine.Excel;
IWorkbook workbook = application.Workbooks.Open(DataPathBase + "TemplateMarker_copy&merge.xlsx");
IWorksheet worksheet = workbook.Worksheets[0];
//Create Template Marker Processor
ITemplateMarkersProcessor marker = workbook.CreateTemplateMarkersProcessor();
IList<Customer> customers = GetSalesReports();
//Add collection to the marker variables where the name should match with input template
marker.AddVariable("Customer", customers);
//Process the markers in the template
marker.ApplyMarkers();
IRange[] mergedCells = worksheet.MergedCells;
foreach(IRange merged in mergedCells)
{
merged.VerticalAlignment = ExcelVAlign.VAlignCenter;
}
workbook.SaveAs(DataPathOutput + "/TemplateMarkerNestedCollection_copy&merge.xlsx");
workbook.Close();
excelEngine.Dispose();
} |
that has nothing to do with images, where did you get the image part ? And the solution you came up with is just a very bad workaround. The template document already have many merged cells with vertical alignment top and you are just setting all merged cells to be vertically centered. Please fix your xlsio library, it shouldn't change the cell alignment after merge.
Also what about the second problem ?
One more thing, the ;merge doesnt work with ;insert:copystyles,copymerges
Thank you
|
Query |
Response |
|
One more thing, the ;merge doesnt work with ;insert:copystyles,copymerges |
We are able to reproduce the issue and we will include this fix also in the weekly NuGet release. |
Thank you.
When I click on track link you provided, it says
when is it going to release ?
Hi John,
As promised earlier The cell text alignment is not proper while using the merge argument in the Template Marker fix is included in the 2022 Vol1 main release. And We are glad to announce that our Essential Studio 2022 Volume 1 release v20.1.0.47 is rolled out and is available for download under the following link.
We thank you for your support and appreciate your patience in waiting for this release. Please contact us if you would require any further assistance.
You can track the status of the defect report through the following feedback link.
Track Status: https://www.syncfusion.com/feedback/32328/the-cell-text-alignment-is-not-proper-while-using-the-merge-argument-in-the
Regards,
Ramya.
Still doesn't work with
%Name;insert:copystyles,copymerges;merge:preservestyle
if the cell is merged by 2 columns
Hi John,
We request you to share the input Excel document you are using at your end to investigate the issue further.
Regards,
Keerthi.
Try this, the second column will have border problems because its merged by 2 columns.
Hi John,
Thanks for sharing the file. We will get back to you with details on April 20th,2022.
We appreciate your patience.
Regards,
Keerthi.
Hi John,
We deeply regret for the inconvenience.
We are facing complexity in analyzing the query and request you 1 more day timeline to check this. We will share the details on April 21st,2022.
Regards,
Keerthi.
Hi John,
We appreciate your patience.
We can reproduce the reported border issue and we are also facing the corruption issue while the input file contains the merged columns. We have attached the sample which was tried at our end. Kindly confirm us if you are facing the same issue. A complete sample can be downloaded from below the link.
Sample link - https://www.syncfusion.com/downloads/support/directtrac/general/ze/F172299_ColumnMerge-1493878343
Regards,
Ramya.
Yes, its worse in example. Please have it fixed.
Hi John,
Thanks for the confirmation.
We have confirmed the issue as Merged cell borders are removed due to file corruption while importing data using template markers and logging a defect report. We will include the fix for this issue in our upcoming weekly NuGet release scheduled for May 10, 2022.
You can track the status of the defect report through the following feedback link.
Track Status: https://www.syncfusion.com/feedback/34392/merged-cell-borders-are-removed-due-to-file-corruption-while-importing-data-using
We will let you know once the new package version is available on nuget.org.
Disclaimer: Inclusion of this solution in the weekly release may change due to other factors including but not limited to QA checks and works reprioritization.
Regards,
Ramya.
Hi John,
We have planned for the 2022 Volume 1 SP release this week, so there is no Weekly NuGet release today. We will be having the weekly NuGet release next week and will update you once it is published.
We appreciate your patience until then.
Regards,
Ramya
Hi John,
We appreciate your patience.
We have included the fix to resolve the issue Merged cell borders are removed due to file corruption while importing data using template markers in our weekly NuGet release version 20.1.0.56. Kindly upgrade your Syncfusion packages to this new 20.1.0.56 version and let us know if the issue is resolved.
Regards,
Keerthi.
I do not want to use
NuGet release, when will it releases on website?
Hi John,
This fix will be included in our 2022 Volume 2 main release, which is expected to be rolled out by the end of June 2022. We will let you know once the release is rolled out.
We appreciate your patience.
Regards,
Ramya.
Hi John,
We are glad to announce that our Essential Studio 2022 Volume 2 release v20.2.0.36 is rolled out and is available for download under the following link.
We have included the fix to resolve the issue Merged cell borders are removed due to file corruption while importing data using template markers in our 2022 Volume 2 release.
Track Status: https://www.syncfusion.com/feedback/34392/merged-cell-borders-are-removed-due-to-file-corruption-while-importing-data-using
We thank you for your support and appreciate your patience in waiting for this release. Please get in touch with us if you would require any further assistance.
Regards,
Ramya.
Still have the same problem, did you even check the sample I provided with new assemblies ?
Hi John,
As mentioned earlier, we have included the fix in our 2022 Volume 2 main release. And we have checked the issue in the latest NuGet, in which the issue is resolved. So, kindly delete the bin and obj folder from the sample and upgrade your Syncfusion packages to this new 20.2.0.43 or 20.2.0.36 [2022 Volume 2 main release version ] and let us know if the issue is resolved.
We have attached the generated Output file for your reference.
Output file - https://www.syncfusion.com/downloads/support/directtrac/general/ze/Output-1332849578
Regards,
Ramya