Thread: [SOLVED] Progress
View Single Post
  #23  
Old 07-01-2016, 03:00 AM
rojam rojam is offline
Senior Member
 
Join Date: Jun 2015
Posts: 200
Default

Quote:
Originally Posted by robert View Post
If i use this approach

Code:
Procedure TForm1.Timer1Timer(Sender: TObject);
begin
  Gauge.Progress := Gauge.Progress + 1;
  Edit1.Text := StrToInt(Gauge.Progress);
  ...
  Richedit.SelText := ('waiting '+ edit.text);
  Timer1.Enabled := Gauge.Progress = Gauge.MaxValue;
end;
in RichEdit lines are added as soon as guage is stepping ahead

waiting 1
waiting 2
waiting 3
-----
----
waiting 100

this makes a mess like .. whereas I was trying to achieve it in progressive manner.

waiting 1 then after 2 then after 3 and so on

I am really surprised that masters are getting failed to advise for this properly whereas I have an Delphi made exe. doing this

in exe. the line after lot of lines shows like text progress percentage with gauge progress.
Well, I have to turn it around on you in that I am amazed that you expect us to somehow read your mind and figure out what you want your application to do. Re-read your first post

Quote:
I am trying to achieve to get the Guage progress in Edit1 while Guage is updating so far I tried but not works

Edit.Text:=(IntToStr(Gauge1.Progress));
You mention absolutely nothing about a richedit, you simply are asking how to put the gauge's progress into an edit control.....

If you want to change what the richedit contains, then you can do so easily enough with
Code:
RichEdit.Text := 'Waiting '+IntToStr(Gauge.Progress);
if you have other text in the richedit that you don't want to overwrite then you can change just the line in question
Code:
RichEdit.Lines[0] := 'Waiting ' + IntToStr(Gauge.Progress);
How Edit1.Text comes into play is a bit difficult for me to understand after following all of your previous posts?