@Jordan Halgunseth, Welcome to Microsoft Q&A,
The try-catch statement consists of a
try
block followed by one or morecatch
clauses, which specify handlers for different exceptions. When an exception is thrown, the common language runtime (CLR) looks for thecatch
statement that handles this exception.
The above sentence comes from Microsoft Learning try-catch (C# Reference), which may help you to learn more about how the try catch works.
You also could look at the example.
Hope my description could help you.
Best Regards,
Jack
If the answer is the right solution, please click "Accept Answer" and upvote it.If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.