When a new instance of the object context class is created, it should be created using the using statement. It's because, in .NET, when a variable goes out of scope - the garbage collector retrieves its memory at its own time. The ObjectContext class holds resources including database connections which should be released when done. To achieve this, the using statement should be used. When the using code block is completed, the Dispose() method is called that closes the database connection and releases memory from all other unused objects from the using code block.