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

Default Save Format Param

1 Answer 120 Views
RichTextBox
This is a migrated thread and some comments may be shown as answers.
Marcello
Top achievements
Rank 1
Iron
Marcello asked on 12 Dec 2014, 09:02 AM
Hi,

How to show the default file format as pdf clicking the save button in RadRichTextBox Ribbon Bar?
Perhaps a parameter in the SaveCommand?

Thanks,
marc.








1 Answer, 1 is accepted

Sort by
0
Todor
Telerik team
answered on 16 Dec 2014, 01:04 PM
Hello Marcello,

You are correct - the dialog's file filter could be passed as a CommandParameter to the SaveCommand command. For example, if you want to export only Pdf or Rtf files, you can use the following markup in the declaration of the RadRichTextBoxRibbonUI:
<telerik:RadRibbonButton telerik:RadRichTextBoxRibbonUI.RichTextCommand="{Binding SaveCommand}" CommandParameter="PDF Files (*.pdf)|*.pdf|Rich Text Format (*.rtf)|*.rtf" Size="Small" SmallImage="pack://application:,,,/Telerik.Windows.Controls.RichTextBoxUI;component/Images/MSOffice/16/save.png" Text="Save"/>

In order you want to export only Pdf files, you can set the CommandParameter property to 'pdf' string only.

I hope this helps.

Regards,
Todor
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
RichTextBox
Asked by
Marcello
Top achievements
Rank 1
Iron
Answers by
Todor
Telerik team
Share this question
or