How to correctly write Try..Finally..Except statements?
You just need two try/finally blocks: Screen.Cursor:= crHourGlass; try Obj:= TSomeObject.Create; try // do something finally Obj.Free; end; finally Screen.Cursor:= crDefault; end; The guideline to follow is that you should use finally rather than except for protecting resources. As you have observed, if you attempt to do it with except then you are forced to … Read more