- This topic has 3 replies, 2 voices, and was last updated 5 years, 2 months ago by .
Viewing 3 reply threads
Viewing 3 reply threads
- You must be logged in to reply to this topic.
hi,kim
The following code will not trigger WhenException.
procedure TForm4.Button1Click(Sender: TObject);
begin
Scheduler.Run([Task1,Task2])
.WhenException(procedure(const AException:Exception)
begin
ShowMessage(AException.Message);
end)
.Activate;
end;
procedure TForm4.Task1(const AScheduledEvent: IkbmMWScheduledEvent);
begin
raise Exception.Create(‘Task1 Exception.’);
end;
procedure TForm4.Task2(const AScheduledEvent: IkbmMWScheduledEvent);
begin
raise Exception.Create(‘Task2 Exception.’);
end;
best regards
Tom YU.
Code written like the following will not trigger WhenException.
Scheduler.Run(Task1)
.WhenException(procedure(const AException:Exception)
begin
ShowMessage(AException.Message);
end)
.Activate;
WhenException for Run with multiple tasks will be fixed in next release.
WhenException for Run with single task (no array of tasks) already works.
hi,kim
5.13 fixed!
thank you!
best regards
TomYU