c# empty catch block – exception handling

Categories: Programming
Tags:
Comments: No Comments
Published on: June 5, 2010

Empty catch block is designed to catch any unhandled exceptions.

public void aFunction(){

try
{

// …

}
catch
{
// Any unhandled exception

throw;

}

}

in exception hierarchy, catch block is in the highest hierarchy. This is called General Catch Block.

Share this

Welcome , today is Tuesday, February 7, 2012

Bad Behavior has blocked 251 access attempts in the last 7 days.