You can use a try-except block like so:
try
begin
Example(6);
Example(8);
Example(10);
Example(15);
Example(7);
Example(1);
end
except on E: Exception do
raise Exception.Create(E.Message); // raised as a new exception so will include the line calling Example(15) as the error line
end;
darkagn
Veteran Poster
1,197 posts since Aug 2007
Reputation Points: 404
Solved Threads: 200