Spire.Doc is a professional Word .NET library specifically designed for developers to create, read, write, convert and print Word document files. Get free and professional technical support for Spire.Doc for .NET, Java, Android, C++, Python.

Wed Apr 08, 2015 8:02 pm

I am trying out the Spire.Doc
when I save from windows richtextbox, it does not save the formatting

eg: fonts, color bold etc

how is this done??
here is my code

Dim doc As New Document

'Create word document
Dim document As New Document()

'Create a new section
Dim section As Section = document.AddSection()

'Create a new paragraph
Dim paragraph As Paragraph = section.AddParagraph()

'Append Text
paragraph.AppendText(rtbTest.Rtf)

'Save doc file.
document.SaveToFile("Sample.doc", FileFormat.Docx)

robert11
 
Posts: 2
Joined: Wed Apr 08, 2015 7:19 am

Thu Apr 09, 2015 7:02 am

Hello,

Thanks for your inquiry.
Please try the Paragraph.AppendRTF( ) method instead of the Paragraph.AppendText() method.
If there are any questions, welcome to get it back to us.

Sincerely,
Betsy
E-iceblue support team
User avatar

Betsy
 
Posts: 802
Joined: Mon Jan 19, 2015 6:14 am

Fri Apr 10, 2015 8:21 am

Hello,

Has your issue been resolved? Could you please give us some feedback at your convenience?

Thanks,
Betsy
E-iceblue support team
User avatar

Betsy
 
Posts: 802
Joined: Mon Jan 19, 2015 6:14 am

Mon Apr 13, 2015 2:42 pm

Will try that out once I am off work
Thanks!

robert11
 
Posts: 2
Joined: Wed Apr 08, 2015 7:19 am

Fri Apr 24, 2015 3:24 am

Hello,

Have you tried the method? Has your issue been resolved ?
Thanks for your response.

Sincerely,
Betsy
E-iceblue support team
User avatar

Betsy
 
Posts: 802
Joined: Mon Jan 19, 2015 6:14 am

Return to Spire.Doc