In VB.NET (as well as C#), structured exception-handling code detects and responds to errors during execution by combining a control structure with exceptions, protected blocks of code, and filters.