I'm trying to use the C# gdal bindings but I get an error in my C# code which says "Unable to load DLL 'gdal_wrap': The specified module could not be found. (Exception from HRESULT: 0x8007007E)".

I've had a look at the dependencies for gdal_csharp.dll and everything looks okay. Two things that stood out though were that the csharp dll is a 32 bit dll, while all the dependencies are for a 64 bit system (my machine has a 64 bit CPU). Also, the file ieshims.dll was listed as a dependency, but from what I gather, it isn't strictly necessary that it be installed.

I've tried installing the files manually via a zip file and also using the .msi installer for the gdal core libraries. I made sure to add the paths to the gdal executables to my system path.

I downloaded the binaries from here: http://www.gisinternals.com/query.html?content=filelist&file=release-1800-x64-gdal-1-11-1-mapserver-6-4-1.zip

And I roughly followed this guide for installation instructions: http://vipassanaandenvironmentalinformatics.blogspot.co.nz/2013/03/getting-started-with-c-and-gdal.html

I'm using Visual Studio 2013, for which the binaries are available on the site above.

  • 2
    Does this question help? stackoverflow.com/q/14353502/2258 Mar 9, 2015 at 21:56
  • Thanks for posting that question, I put the gdal_wrap.dll into dependency walker and it turns out that there is a missing dependency called gdal111.dll, I'll try to track this down and post an update on my progress. Mar 9, 2015 at 22:13
  • @AndreLashley I am getting the same issue with unable to load gdal_wrap. Any suggestions? Aug 12, 2015 at 12:28
  • @StealthRabbi I ended up using the gdal command line tools via OSGEO4W and C# code. It was much easier to set up this way. But of course you don't get all the benefits of using the C# gdal libraries. Aug 12, 2015 at 16:40
  • 1
    Don't know if you ever solved this, but this turned up for me trying to solve the same issue, and I ended up adding an answer to the SO question link in comment number one which solved the issue. If it helps I'll happily post it as a question on this question too. SO-GIS seems a more appropriate place anyway.
    – shawty
    Jun 24, 2016 at 21:32

1 Answer 1


Get the package from NuGet and then you need to call static methodGdalConfiguration.ConfigureGdal() from GdalConfiguration.cs/vb at startup to set process environmental variables. Call GdalConfiguration.ConfigureOgr() if you want to use OGR as well.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.