This question is locked. New answers and comments are not allowed.
I am building a RadDocument in code-behind, but don't want to assign it to a RadRichTextBox. Rather, I want to be able to print the RadDocument. Any examples are recommendations on how to do this?
3 Answers, 1 is accepted
0
Hello GEB,
Currently the only way available to to print a document is through RadRichTextBox API. In the case with Silverlight printing the rich text box instance should be added to the the application element tree in order for printing to work correctly.
I've prepared you a sample application that demonstrates the possible approach to printing RadDocument using both Silverlight and Html printing.
Regards,
Mike
the Telerik team
Currently the only way available to to print a document is through RadRichTextBox API. In the case with Silverlight printing the rich text box instance should be added to the the application element tree in order for printing to work correctly.
I've prepared you a sample application that demonstrates the possible approach to printing RadDocument using both Silverlight and Html printing.
Regards,
Mike
the Telerik team
Do you want to have your say when we set our development plans?
Do you want to know when a feature you care about is added or when a bug fixed?
Explore the
Telerik Public Issue Tracking
system and vote to affect the priority of the items
0
GEB
Top achievements
Rank 1
answered on 23 Sep 2010, 09:20 AM
Mike, thanks for the quick response. Your example application was exactly what I needed, and I was able to successfully implement the printing feature in my SL4 application. I have chosen to use Silverlight printing rather than HTML printing.
I do have a follow up question, though. In my Silverlight application, I am also using the Telerik Report Viewer. Are there any examples of incorporating a XAML-based document into a report? In my case, the XAML will be created using RadRichTextBox (similar to the Telerik MS Word editor example), and the resulting XAML will be stored in a SQL Server database. The Telerik reporting environment, using the SL Viewer, will be used to print reports from the database. There are some reports where I would like to print the XAML created using RadRichTextBox. Any help/direction would be appreciated.
If it is more appropriate, I can open a new thread under Telerik Reporting.
I do have a follow up question, though. In my Silverlight application, I am also using the Telerik Report Viewer. Are there any examples of incorporating a XAML-based document into a report? In my case, the XAML will be created using RadRichTextBox (similar to the Telerik MS Word editor example), and the resulting XAML will be stored in a SQL Server database. The Telerik reporting environment, using the SL Viewer, will be used to print reports from the database. There are some reports where I would like to print the XAML created using RadRichTextBox. Any help/direction would be appreciated.
If it is more appropriate, I can open a new thread under Telerik Reporting.
0
Hello GEB,
Interoperability with the reporting solution is achieved by the means of HTML. If you store your documents in XAML, you'll need to import them into a RadDocument and export them to HTML before passing them forward to reporting.
The reporting team is currently working on a help article to explain how the HtmlFormatProvider needs to be configured in order to make it work with their HTML parser. However, since this is not ready yet, here's what you need to do in order to make the HTML compatible:
The HtmlFormatProvider has a property named ExportSettings which is of type HtmlExportSettings. You need to create an instance of the settings class and assign the following properties:
All the best,
Ivailo
the Telerik team
Interoperability with the reporting solution is achieved by the means of HTML. If you store your documents in XAML, you'll need to import them into a RadDocument and export them to HTML before passing them forward to reporting.
The reporting team is currently working on a help article to explain how the HtmlFormatProvider needs to be configured in order to make it work with their HTML parser. However, since this is not ready yet, here's what you need to do in order to make the HTML compatible:
The HtmlFormatProvider has a property named ExportSettings which is of type HtmlExportSettings. You need to create an instance of the settings class and assign the following properties:
- ImageExportMode = ImageExportMode.None;
- StylesExportMode = StylesExportMode.Inline;
- DocumentExportLevel = DocumentExportLevel.Fragment;
All the best,
Ivailo
the Telerik team
Do you want to have your say when we set our development plans?
Do you want to know when a feature you care about is added or when a bug fixed?
Explore the
Telerik Public Issue Tracking
system and vote to affect the priority of the items