Approved
Last Updated: 15 Oct 2019 10:25 by ADMIN
Sajid
Created on: 20 Feb 2019 07:05
Category: UI for WPF
Type: Bug Report
2
RichTextBox: Fields in header/footer loose their formatting when the document is exported to DOCX and RTF
When a document is imported (for example from XAML) and then exported to DOCX or RTF, the fields lose their formatting. The issue is not observed if the document is just created.
Workaround: Change the fields display mode of all fields in headers/footers just before the export:
private void UpdateHeadersFooters(RadDocument document)
{
    foreach (Section section in document.Sections)
    {
        if (section.Headers.Default.Body != null)
        {
            this.UpdateFields(section.Headers.Default.Body);
        }
 
        if (section.Headers.First.Body != null)
        {
            this.UpdateFields(section.Headers.First.Body);
        }
 
        if (section.Headers.Even.Body != null)
        {
            this.UpdateFields(section.Headers.Even.Body);
        }
 
        if (section.Footers.Default.Body != null)
        {
            this.UpdateFields(section.Footers.Default.Body);
        }
 
        if (section.Footers.First.Body != null)
        {
            this.UpdateFields(section.Footers.First.Body);
        }
 
        if (section.Footers.Even.Body != null)
        {
            this.UpdateFields(section.Footers.Even.Body);
        }
    }
}
 
private void UpdateFields(RadDocument radDocument)
{
    RadDocumentEditor editor = new RadDocumentEditor(radDocument);
    editor.ChangeAllFieldsDisplayMode(FieldDisplayMode.Code);
}
2 comments
ADMIN
Peshito
Posted on: 15 Oct 2019 10:25

Hi Sajid,

This item did not qualify to be fixed for the current release. I understand this may be of great importance to your project however, I cannot commit to a specific timeframe when it will be fixed. We constantly monitor and reprioritize our backlog and depending on the impact they have and the requests we receive we might or might not include an issue in the planned items for the release. In case you have subscribed to the issue, you will be notified by email for any status change this item will have.

Regards,
Peshito
Progress Telerik

Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Sajid
Posted on: 14 Oct 2019 06:08
Any update on this?