WordsProcessing: Date and Numeric formatting of merge field is not respected
In the document produced by the mail merge, the date time and numeric formatting applied are not respected and the value is in its default format.
10 comments
ADMIN
Martin
Posted on:24 Jun 2021 10:24
Hi Rene,
Thank you for the additional information. I will dive straight to the points:
This behavior is expected when instead of the quotation mark (") a left/right double quotation mark is used (“ & ”). More information on the different quotation mark types can be found in the table in this article. In order to avoid this, I could recommend assuring using the quotation mark (").
I tried to reproduce the described behavior using the provided format and the mentioned assemblies version but on my end, it works as expected. The formated text after mailmerging is in the following format:
Friday, May 28, 2021
In order to demonstrate what exactly I am testing, I am attaching the updated project.
If this is not the case, please, update the project and send it back to us so you can help us to reproduce this behavior.
Regards,
Martin
Progress Telerik
Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.
Downloaded today Telerik UI for WPF internal build Telerik_UI_for_WPF_2021_2_524_Dev_Hotfix.zip
Testing it, Date formatting of date merge field still NOT RESPECTED.
Below is the format I am using
{MERGEFIELD Date \@ "dddd, MMMM d, yyyy" }
ADMIN
Martin
Posted on:20 May 2021 11:56
Hi,
I tested this functionality by creating a sample project using the provided formattings ("Date-Time Pictures") and on my end, it works as expected (check WordsProcessing_Formatting.zip).
I inserted the fields in the following way by preserving the type of the quotation marks (the first formatting uses left and right double quotation marks):
which later imported with DocxFormatProvider, mailmerged again and the result was the same (check WordsProcessing_MergeFieldsFormatting_ImportDocxTemplate.zip).
I am attaching both the projects I created in order to test this functionality. Please feel free to modify them in a way closer to your scenario.
If your scenario is different than the described, please, give us more information on it in order to investigate the case.
The issue is already in development and the fix will be available in the next internal build. Officially the fix will be available in the next service pack as well.
I hope this helps. Should you have any other questions do not hesitate to ask.
Regards,
Dimitar
Progress Telerik
Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.
Coopbase
Posted on:11 May 2021 13:16
Come on guys.
You got to fix this issue. 2017, that is almost 5 years?