[lazarus] TEdit, TProgress

Shane Miller SMiller1 at stvgb.org
Tue Apr 18 08:47:43 EDT 2000


HAve you tried putting an 
Appication.ProcessMessages;
within your loop?  Currently this will slow you down a bit but it should (may) work.
Shane


>>> mbm at diprintas.lt 04/18/00 02:34AM >>>
Hi, all!

See, I have a BIG trouble with TProgress: when my program is COPYING some
file, and I
wanna to show for user how many bytes (percent) is away ;) -- progress is
like died and window (widget, form...) is completely FROZED, while process.
:-(

Here is example (for understanding only):

...
someform_with_progress.show;
...
while not eof(somefile) do
    begin
       read(somefile,someblock);
//       inc(myprogress.position);  -- here error :-(
         myprogress.position:=myprogress.position+1;  // ughhh... Pascal...
Why not '+=' ?

// So here POSITION must RUN,

// buddy... window is completely

// FROZED, until EOF :-(

// On Delphi4 this code-example is working OK.
      write(some_another_file,someblock);
    end;

// someform_with_progress.hide; -- error, coz` I can't to hide a widget :-(
someform_with_progress.close;


So.... What I can to do?
Another trouble: TEdit.OnChange -- is compilling without errors, but... it's
NOT REAL
event. It's just... nothing happend... :-(






_________________________________________________________________
     To unsubscribe: mail lazarus-request at miraclec.com with
                "unsubscribe" as the Subject
    archives at http://www.miraclec.com/list_archives/lazarus






More information about the Lazarus mailing list