<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:times new roman,new york,times,serif;font-size:12pt"><div>Oh, good point to discuss about the use of exceptions.<br><br>I use exceptions only for really "unexpected" things.<br>That a user will sometimes input wrong data must be expected by a programmer so<br>I do not treat this as an exception.<br><br>With unexpected things I mean all the things that are outside my code.<br>e.g.<br> try<br> FExcel := GetActiveOleObject('Excel.Application');<br> except<br> //do something <br> end;<br></div><div style="font-family: times new roman,new york,times,serif; font-size: 12pt;"><br><br><br><div style="font-family: arial,helvetica,sans-serif; font-size: 13px;"><font size="2" face="Tahoma"><hr size="1"><b><span style="font-weight: bold;">Von:</span></b> Michael Van Canneyt
<michael.vancanneyt@wisa.be><br><b><span style="font-weight: bold;">An:</span></b> Lazarus mailing list <lazarus@lazarus.freepascal.org><br><b><span style="font-weight: bold;">Gesendet:</span></b> Montag, den 16. März 2009, 14:14:56 Uhr<br><b><span style="font-weight: bold;">Betreff:</span></b> [Lazarus] Exception dialog<br></font><br>Hello,<br><br>Is there a reason why the default exception dialog has a cancel <br>button to kill the application ?<br><br>We often use an exception to signal wrong entry of data or so, <br>because it stops all further processing.<br><br>If the user then uses the cancel button, the program is simply <br>ended, which is not what we (or better: the users) want.<br>And I imagine many others use this technique.<br><br>I have overridden the OnException handler of TApplication, <br>so it's no longer a problem, but I was curious as to why this<br>is done like this by default
?<br><br>Michael.<br>_______________________________________________<br>Lazarus mailing list<br><a ymailto="mailto:Lazarus@lazarus.freepascal.org" href="mailto:Lazarus@lazarus.freepascal.org">Lazarus@lazarus.freepascal.org</a><br><a href="http://www.lazarus.freepascal.org/mailman/listinfo/lazarus" target="_blank">http://www.lazarus.freepascal.org/mailman/listinfo/lazarus</a><br></div></div></div><br>
</body></html>