Close the Dataset. This method is also called by Dispose(). Do not invoke any methods on a Dataset after closing it!
Dataset Class | Gdal Namespace