Unplanned
Last Updated: 17 Apr 2023 13:44 by James
James
Created on: 17 Apr 2023 13:44
Category: RichTextBox
Type: Bug Report
0
RichTextBox: XamlFormatProvider: KeyNotFoundException when loading a document with a custom bibliographic style applied

KeyNotFoundException is thrown when loading a document with a custom bibliographic style applied.

As a workaround, you can change the current bibliographic style to one of the predefined styles before the export of the document.

...
this.radRichTextBox.CommandExecuting += RadRichTextBox_CommandExecuting;
...

...
private void RadRichTextBox_CommandExecuting(object sender, CommandExecutingEventArgs e)
{
    if (e.Command is SaveCommand)
    {
        this.radRichTextBox.ChangeBibliographicStyle(new APAFifthEditionStyle());
    }
}

0 comments