View Full Version : Stopping a timer while displaying the exception dialog
Hugo Olsen
28-Sep-2005, 10:21 AM
Hi,
I'm trying to implement EurekaLog in my program, but
I need to stop a running timer while the exception
dialog are shown and restarted again when the dialog
are closed.
In my ExceptionNotify procedure I can stop the timer:
procedure MyNotify(ExcRecord: TEurekaExceptionRecord; var Handled:
Boolean);
begin
Form1.Timer1.Enabled := false;
end;
but how do I reenable the timer again?
best regards
Hugo
admin
28-Sep-2005, 05:51 PM
Hugo Olsen wrote:
> Hi,
>
> I'm trying to implement EurekaLog in my program, but
> I need to stop a running timer while the exception
> dialog are shown and restarted again when the dialog
> are closed.
>
> In my ExceptionNotify procedure I can stop the timer:
>
> procedure MyNotify(ExcRecord: TEurekaExceptionRecord; var Handled:
> Boolean);
> begin
> Form1.Timer1.Enabled := false;
> end;
>
>
> but how do I reenable the timer again?
>
> best regards
> Hugo
Use an ExceptionActionNotify event like this:
uses
ExceptionLog, ECore, ETypes; // The required units...
procedure MyActionNotify(EurekaExceptionRecord: TEurekaExceptionRecord;
EurekaAction: TEurekaActionType; var Execute: Boolean);
begin
if (Action = atShowingExceptionInfo) then
Form1.Timer1.Enabled := false
else
if (Action = atShowedExceptionInfo) then
Form1.Timer1.Enabled := true;
end;
--
Best regards...
Fabio Dell'Aria.
----------------
http://www.eurekalog.com
Catch every BUG showing line n.
Hugo Olsen
29-Sep-2005, 07:41 AM
admin wrote:
>
> Use an ExceptionActionNotify event like this:
>
> uses
> ExceptionLog, ECore, ETypes; // The required units...
>
> procedure MyActionNotify(EurekaExceptionRecord: TEurekaExceptionRecord;
> EurekaAction: TEurekaActionType; var Execute: Boolean);
> begin
> if (Action = atShowingExceptionInfo) then
> Form1.Timer1.Enabled := false
> else
> if (Action = atShowedExceptionInfo) then
> Form1.Timer1.Enabled := true;
> end;
>
Great, that worked :-)
Thanks.
vBulletin® v3.8.2, Copyright ©2000-2012, Jelsoft Enterprises Ltd.