<p>Am 10.07.2017 15:46 schrieb "Graeme Geldenhuys" <<a href="mailto:mailinglists@geldenhuys.co.uk">mailinglists@geldenhuys.co.uk</a>>:<br>
><br>
> On 2017-07-10 13:34, Dmitry Boyarintsev wrote:<br>
>><br>
>> are you referring to "Catching More Than One Type of Exception with One<br>
>> Exception Handler" in<br>
>> <a href="https://docs.oracle.com/javase/tutorial/essential/exceptions/catch.html">https://docs.oracle.com/javase/tutorial/essential/exceptions/catch.html</a><br>
><br>
><br>
> Yes. You can have multiple catch blocks inside the same try block. You can also have a single catch block with a comma separated list of exception types.</p>
<p>You can catch multiple exception types in Object Pascal as well:</p>
<p>=== code begin ===</p>
<p>try<br>
expect<br>
on e: EWhatever do ...;<br>
on e: EFoobar do ...;<br>
else ...<br>
end;</p>
<p>=== code end ===</p>
<p>Though you can't use the same code block for multiple types.</p>
<p>Regards,<br>
Sven</p>