Binding contents to DataSource

2 posts, 0 answers
  1. Ashley
    Ashley avatar
    3 posts
    Member since:
    Nov 2012

    Posted 11 Dec 2012 Link to this post


    I am trying to get a RadRichTextBox to be automatically populated with the contents of a field from an Oracle database. I have set up the properties in the same way that I would for a regular Windows Forms Rich Text Box - by setting the DataBindings Text property to be the BindingSource followed by the field name.

    This is working for a regular RichTextBox, however the RadRichTextBox remains empty.

    I have attached a screenshot of the Properties window so you can see exactly what I've set.

    Any ideas would be appreciated.

  2. Svett
    Svett avatar
    728 posts

    Posted 14 Dec 2012 Link to this post

    Hello Ashley,

    You should use the TextFormatProvider to import plain text in RadRichTextBox:

    TxtFormatProvider provider = new TxtFormatProvider();
    this.radRichTextBox1.Document = provider.Import("Your Text");

    You can read more about format providers in the online documentation. Greetings,
    the Telerik team
    Q3’12 of RadControls for WinForms is available for download (see what's new). Get it today.
Back to Top