This is a migrated thread and some comments may be shown as answers.

TextBlock for dynamic data

1 Answer 62 Views
RichTextBox
This is a migrated thread and some comments may be shown as answers.
Oscar Arturo
Top achievements
Rank 1
Oscar Arturo asked on 26 Nov 2011, 12:57 PM
Hi everyone! I am using RadRichTextBox as a WordProcessor. I want to add a TextBlock into de RTB to let the user type data into it but, this processor is just to make a LayOut of a report. Later in another module of my system I want to read the content of a previous saved report and seek for the TextBlock, the user will enter date into a Prompt and the value of TextBlock will change. I want to save the report with OpenXML format (To make images portables)... so I think the TextBlock will be dismissed into the Export to Docx. My question is, what would happen if I save the report into OpenXML format, then in the other module I Import this report, then I serialize the RadDocument and seek for the TextBock... is this going to work?

1 Answer, 1 is accepted

Sort by
0
Iva Toteva
Telerik team
answered on 30 Nov 2011, 06:01 PM
Hello Oscar,

UIElements can be embedded in the document only in InlineUIContainers. More information on InlineUIContainers and their export can be found here.
In your particular scenario, if you use a TextBlock, it will be stripped when you export the document to docx and you will not be able to retrieve it later.
What you can do is use the newly introduced DocumentProtection feature. Its use is not described in our official documentation, but you can preview it in our Silverlight online demo and read through the document in the editor for more information on the way it can be used. The same demo is also available for WPF in the resources under your account.

Kind regards,
Iva Toteva
the Telerik team

Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>

Tags
RichTextBox
Asked by
Oscar Arturo
Top achievements
Rank 1
Answers by
Iva Toteva
Telerik team
Share this question
or