[mapserver-users] Re: Problem with ECW files

Frost89 kristian_frost7 at hotmail.com
Tue Jan 18 03:27:42 EST 2011


Problem solved!

I had to add a reference to my Visual Studio project to the gdal_csharp.dll.
Now, I have the GDAL interface when adding using OSGeo.GDAL to my class.
This allows me to use the following code to load the right DLL's:

String gdal_bin_path = @"c:\path\to\my\binaries";

String gdal_driver_path = @"c:\path\to\my\binaries\gdalplugins";

String path = Environment.GetEnvironmentVariable("PATH");


if (!path.Contains(gdal_bin_path)) {

  Environment.SetEnvironmentVariable("PATH", gdal_bin_path + ";" +
path);

}


Gdal.SetConfigOption("GDAL_DRIVER_PATH", gdal_driver_path);
Now the ECW files show up as they are supposed to.

- Kristian Frost

-- 
View this message in context: http://osgeo-org.1803224.n2.nabble.com/Problem-with-ECW-files-tp5918048p5934825.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/mapserver-users/attachments/20110118/c0ea84b0/attachment.html


More information about the mapserver-users mailing list