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

RadRichTextbox with RadRichTextBoxRibbonUI in Prism

1 Answer 99 Views
RichTextBox
This is a migrated thread and some comments may be shown as answers.
Perlom
Top achievements
Rank 1
Perlom asked on 09 Jan 2013, 03:01 AM
Hi,

We are on the design stage for a WPF Prism application, and we want to provide an editor functionality similar to MS Word in one of our modules. We have a toolbar region in the top of the page that should load the module containing the RadRichTextBoxRibbonUI, and a content region in the middle of the screen that should load the module containing the RadRichTextbox for editing. So the Rich Textbox and its Ribbon are in 2 separate module for loose coupling. In the WPF demo examples, the commands in Ribbon are bound the RichTextbox in XAML (i.e. DataContext and Commands). Is there any suggestion how can we implement our design? Can we pass a reference of the RichTextbox and do the necessary binding in the code at load time of the ribbon?

Any hints would be appreciated!

Regards

1 Answer, 1 is accepted

Sort by
0
Boby
Telerik team
answered on 11 Jan 2013, 08:42 AM
Hello Perlom,
There shouldn't be any problems to set the data context of the ribbon at a later time (e.g. on ribbon load). Setting the RichTextBoxCommands object from RadRichTextBox.Commands property as RadRichTextBoxRibbonUI.DataContext should do the work.

Regards,
Boby
the Telerik team

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Tags
RichTextBox
Asked by
Perlom
Top achievements
Rank 1
Answers by
Boby
Telerik team
Share this question
or