Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Try Catch Finally
Message
De
11/01/2003 14:11:04
 
 
À
10/01/2003 13:23:25
Information générale
Forum:
ASP.NET
Catégorie:
Autre
Divers
Thread ID:
00740398
Message ID:
00740673
Vues:
14
Hi Alex,

What is the Finally used for if it is always executed? Just place the Finally code after the End Try.

What I was trying to determine if the try command had a way to execute code if no errors occurred.

I am a beginner in Vb .net.

Thanks
Roland
===========================================================================


>>The Try,Catch,Finally documentation states
>>
>>Execution enters the Try...Catch...Finally block with the statement block following the Try statement. If Visual Basic completes this block without an exception being generated, it looks for the optional Finally statement at the end.
>>
>>-
>>-
>>
>>No matter what happens, the Finally block is always the last code to be executed before leaving Try...Catch...Finally.
>>
>>
>>My question is: Does the Finally block get executed if a catch is executed?
>>
>>Reading the above is confusing!
>>
>>Thanks
>>Roland

>
>AFAIK, yes it is, no matter what.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform