The following code works well on D2005 :
MyRichEdit1.Text := TMemoField(Query1.FieldByName('Msg')).asString;
But in D2010, this code outputs the text in plain text and not on rtf.
To solve the problem I'm using the following code
MyRichEdit1.PlainText := False;
MyRichEdit1.Text := TMemoField(Query1.FieldByName('Msg')).asString;
MyRichEdit1.PlainText := TRUE;
MyRichEdit1.Lines.SaveToFile('Lixo.Rtf');
MyRichEdit1.PlainText := False;
MyRichEdit1.Lines.LoadFromFile('Lixo.Rtf');
How can I import rtf text from a database to a TRichEdit without having to use a file in the process? I tried the solution on this question but it doesn't work, it appear in plain text and with a space between each char.
Thanks Sam