Qus:    What is the use of a finally block in exception handling?
Dec 15, 2020 15:57 DotNet 2 Answers Views: 1318 DIVYA

You can use a finally block if you want to clean up any resources that are allocated in a try block, and you can run code even if an exception occurs in the try block.

Prev Next
Answers (2)
PARTH Dec 16, 2020 13:26
Answer:   You can use a finally block if you want to clean up any resources that are allocated in a try block, and you can run code even if an exception occurs in the try block.

FRAUSKY Dec 16, 2020 19:01
Answer:   Finally block is used to free resources such as database connection , objects used within the try block.

Post Your Answer
Guest User

Not sure what solution is right for you?

Choose the right one for you.
Get the help of the experts and find a solution that best suits your needs.


Let`s Connect