Solved

Richedit

Posted on 2002-04-26
2
274 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

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
Save pdf file to other location 3 72
loading dll from external path 1 197
Simple Delphi Question 9 77
Delphi - replicating a form 8 57
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
In my programming career I have only very rarely run into situations where operator overloading would be of any use in my work.  Normally those situations involved math with either overly large numbers (hundreds of thousands of digits or accuracy re…
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

705 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

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now