RichTextBox in TabControl/TabPage

2 posts, 0 answers
  1. Dirk Klimke
    Dirk Klimke avatar
    2 posts
    Member since:
    Nov 2009

    Posted 28 Apr 2011 Link to this post


    We have a view with a TabControl. This TabControl has two TabItems. One of the TabItems has a RichTextBox control as you can see in the example.
    We are using the MVVM pattern and we want to bind a String-property to the RichTextBox-control, which contains HTML-text.
    On changing the tab after entering a text, the property in the viewmodel contains still the right HTML-text.
    But after re-entering the tab with the RichTextBox, the control only shows an empty document.

    Any ideas?

    Note: We're unable to upload a sample project. Please tell us how we can upload code samples.

  2. Iva Toteva
    Iva Toteva avatar
    1319 posts

    Posted 29 Apr 2011 Link to this post

    Hi Dirk Klimke,

    As discussed in the support ticket, the reason seems to be that the custom control containing a RadRichTextBox is inside a DataTemplate. Declaring the content of the RadTabItems directly, not through a template solved the issue.

    Kind regards,
    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
Back to Top