Solved

Richedit

Posted on 2002-04-26
2
294 Views
Last Modified: 2013-11-22
Procedure BufferRichedit;
Begin
If Form1.RichEdit1.Lines.Count>=MaxLines Then
 begin
   While Form1.RichEdit1.Lines.Count>=MaxLines do
     Form1.RichEdit1.Lines.Delete(0);
  end;
End;

Where MaxLines>300 so as the chat fills up, to stop it from going on forever and ever, it deletes the top lines and then goes back to the bottom, it works - okish..

Problem is everytime it happens it flickers as it moves everything down, is there any other way of doing this? or even buffer it or something, place something on top of it so people do not see it refresh? any suggestions?

- Thanks

Craig C.
0
Comment
Question by:craig_capel
2 Comments
 
LVL 12

Accepted Solution

by:
Lee_Nover earned 50 total points
ID: 6972412
set it's DoubleBuffered property to true
and btw you can ommit the "if part" :)
simply use :
While Form1.RichEdit1.Lines.Count>=MaxLines do
    Form1.RichEdit1.Lines.Delete(0);
0
 
LVL 1

Expert Comment

by:MBo
ID: 6972718
Richedit1.Lines.BeginUpdate;
... your actions here
Richedit1.Lines.EndUpdate;

0

Featured Post

Networking for the Cloud Era

Join Microsoft and Riverbed for a discussion and demonstration of enhancements to SteelConnect:
-One-click orchestration and cloud connectivity in Azure environments
-Tight integration of SD-WAN and WAN optimization capabilities
-Scalability and resiliency equal to a data center

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Printing problem 2 102
how to change, disabled button color FMX ? 1 40
Delphi: barcode reading on android platform 1 51
MS Access from Delphi 31 60
Introduction The parallel port is a very commonly known port, it was widely used to connect a printer to the PC, if you look at the back of your computer, for those who don't have newer computers, there will be a port with 25 pins and a small print…
Introduction Raise your hands if you were as upset with FireMonkey as I was when I discovered that there was no TListview.  I use TListView in almost all of my applications I've written, and I was not going to compromise by resorting to TStringGrid…
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question