Hello:
We are using Aspose.Words 9.4 version and, having a problem with the subscript and superscript in the RichText data displayed in Aspose document. We are using a RichTextBox control to enter the rich text and passing that to a stream and that to the Aspose Document. Below is the code:
MemoryStream textStream = new MemoryStream();
StreamWriter writer = new StreamWriter(textStream);
writer.Write(fieldValue); // where fieldValue = myRichTextBox.rtf See below for the value
writer.Flush();
textStream.Position = 0;
//Read stream into Aspose.Words document.
LoadOptions lo = new LoadOptions(LoadFormat.Rtf, string.Empty, string.Empty);
Document Tempdoc = new Document(textStream, lo);
Tempdoc.Save(@"C:\temp\output.doc");
fieldValue = {\rtf1\ansi\ansicpg1252\deff0\deflang1033{\fonttbl{\f0\fnil\fcharset0 Arial;}}
{\*\generator Msftedit 5.41.21.2509;}\viewkind4\uc1\pard\fs20 How\sub BR549\nosupersub does WordPad do\super BR549\nosupersub it?\par
}
The above rich text value is from myRichTextBox.rtf
The output.doc SHOULD have been: HowBR549
does WordPadBR549 do it?
INSTEAD it is: HowBR549 does WordPad doBR549 it?
(All text after subscript is treated as subscript and same for superscript)
Please help. Thank you.