The using statement in C# is a form of shortcut for try and finally block of code. Things to note is in order to use the using statement the object needs to implement the IDisposable interface, and using does not catch Exception, it just guarantees the call of Dispose.

Example:

Can be replaced with

One will not need to call the Close method of sql connection, since the dispose will do that.