<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal-compose;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-family:"Calibri","sans-serif";}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=EN-US link=blue vlink=purple><div class=WordSection1><p class=MsoNormal>Hi List,<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>I’ve run into a bit of an issue. Using <a href="http://www.gisinternals.com/sdk/PackageList.aspx?file=release-1600-gdal-1-8-0-mapserver-5-6-6.zip">release-1600-gdal-1-8-0-mapserver-5-6-6</a> in my .Net project I cannot get ECW images to draw. I receive this error:<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>msDrawMap(): Image handling error. Failed to draw layer named 'ecw'.;msDrawRaster(): Image handling error. Unrecognized or unsupported image format;drawEPP(): Image handling error. EPPL7 support is not available.<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>I believe that this means that the ECW driver is not found and the EPPL7 is just the last one of the list that Mapserver tried to use. <o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>I am able to generate an image from the mapfile using both shp2img and drawmap when the SDKShell.bat is executed, so I believe that the issue in my .Net app is with environment variables not being set in the .Net application. The application is a web application, but I experience the same issue in a console application. <o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>I’ve tried the guidance from gis.stackexchange pointing to this gdal advice: <a href="https://bitbucket.org/bjartn/gdalgonewild/src/4be6d86fef24/src/GdalGoneWild.Client/GdalEnvironment.cs?at=default">https://bitbucket.org/bjartn/gdalgonewild/src/4be6d86fef24/src/GdalGoneWild.Client/GdalEnvironment.cs?at=default</a> without luck.<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Am I on the right track with the environment variables? Has anyone had any luck setting these environment variables (GDAL_DATA, GDAL_DRIVER, PROJ_LIB) in .Net code for Mapscript use? If so, can you guide me? Or, is there a work around? I am even willing to put everything in the bin directory if that is the only way to make things work.<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Thanks a ton in advance for your assistance.<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Dave Lowther<o:p></o:p></p><p class=MsoNormal>Coordinate Solutions, Inc<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p></div></body></html>