<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:x="urn:schemas-microsoft-com:office:excel" xmlns:p="urn:schemas-microsoft-com:office:powerpoint" xmlns:a="urn:schemas-microsoft-com:office:access" xmlns:dt="uuid:C2F41010-65B3-11d1-A29F-00AA00C14882" xmlns:s="uuid:BDC6E3F0-6DA3-11d1-A2A3-00AA00C14882" xmlns:rs="urn:schemas-microsoft-com:rowset" xmlns:z="#RowsetSchema" xmlns:b="urn:schemas-microsoft-com:office:publisher" xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet" xmlns:c="urn:schemas-microsoft-com:office:component:spreadsheet" xmlns:oa="urn:schemas-microsoft-com:office:activation" xmlns:html="http://www.w3.org/TR/REC-html40" xmlns:q="http://schemas.xmlsoap.org/soap/envelope/" xmlns:D="DAV:" xmlns:x2="http://schemas.microsoft.com/office/excel/2003/xml" xmlns:ois="http://schemas.microsoft.com/sharepoint/soap/ois/" xmlns:dir="http://schemas.microsoft.com/sharepoint/soap/directory/" xmlns:ds="http://www.w3.org/2000/09/xmldsig#" xmlns:dsp="http://schemas.microsoft.com/sharepoint/dsp" xmlns:udc="http://schemas.microsoft.com/data/udc" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:sub="http://schemas.microsoft.com/sharepoint/soap/2002/1/alerts/" xmlns:ec="http://www.w3.org/2001/04/xmlenc#" xmlns:sp="http://schemas.microsoft.com/sharepoint/" xmlns:sps="http://schemas.microsoft.com/sharepoint/soap/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:udcxf="http://schemas.microsoft.com/data/udc/xmlfile" xmlns:wf="http://schemas.microsoft.com/sharepoint/soap/workflow/" xmlns:mver="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns:mrels="http://schemas.openxmlformats.org/package/2006/relationships" xmlns:ex12t="http://schemas.microsoft.com/exchange/services/2006/types" xmlns:ex12m="http://schemas.microsoft.com/exchange/services/2006/messages" xmlns:Z="urn:schemas-microsoft-com:" xmlns:st="&#1;" 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 12 (filtered medium)">
<style>
<!--
 /* Font Definitions */
 @font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
 /* Style Definitions */
 p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","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;}
p
        {mso-style-priority:99;
        mso-margin-top-alt:auto;
        margin-right:0in;
        mso-margin-bottom-alt:auto;
        margin-left:0in;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
span.EmailStyle18
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;}
@page Section1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.Section1
        {page:Section1;}
-->
</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=Section1>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'>I don&#8217;t have experience yet with the latest release&#8230;maybe there
is another DLL dependency that wasn&#8217;t present in my 5.0.2 release.&nbsp; Can you easily
put the 5.0.2 DLLs in your application directory and update the project DLL reference
accordingly and give it a try?<o:p></o:p></span></p>

<p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";
color:#1F497D'><o:p>&nbsp;</o:p></span></p>

<div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'>

<p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span
style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> Nelson Soto
[mailto:nellyfromma@gmail.com] <br>
<b>Sent:</b> Monday, August 25, 2008 11:05 AM<br>
<b>To:</b> Hulbert, Brian<br>
<b>Subject:</b> Re: [mapserver-users] MapServer and .NET?<o:p></o:p></span></p>

</div>

<p class=MsoNormal><o:p>&nbsp;</o:p></p>

<div>

<div>

<p class=MsoNormal>I have tried reference the file in my ms4w install
directory, so:<o:p></o:p></p>

</div>

<div>

<p class=MsoNormal>C:\Program Files\ms4w\Apache\cgi-bin\mapscript\csharp<o:p></o:p></p>

</div>

<div>

<p class=MsoNormal>&nbsp;<o:p></o:p></p>

</div>

<div>

<p class=MsoNormal>This was actually the first thing I tried but it have me the
same error for the first time so I experimented with hunting all dll's and
copying them in the application folder per recommendations but this caused me
to receive the same error. <o:p></o:p></p>

</div>

<div>

<p class=MsoNormal>&nbsp;<o:p></o:p></p>

</div>

<div>

<p class=MsoNormal>&nbsp;<o:p></o:p></p>

</div>

<div>

<p class=MsoNormal>On Mon, Aug 25, 2008 at 9:01 AM, Hulbert, Brian &lt;<a
href="mailto:brian.hulbert@linquest.com">brian.hulbert@linquest.com</a>&gt;
wrote:<o:p></o:p></p>

<div>

<div>

<p><span style='font-size:11.0pt;color:#1F497D'>Nelson,</span><o:p></o:p></p>

<p><span style='font-size:11.0pt;color:#1F497D'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
I avoided recompiling any DLLs.&nbsp; I used what was provided.</span><o:p></o:p></p>

<p><span style='font-size:11.0pt;color:#1F497D'>&nbsp;</span><o:p></o:p></p>

<p><span style='font-size:11.0pt;color:#1F497D'>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
Is your VS project referencing the mapscript DLL in your Debug/Release folder
or is it referencing the one in your C:\Program Files\MS4W folder?&nbsp; Since
I have a C# app, I have a VS project reference to just the mapscript_csharp.dll
file in a common 3<sup>rd</sup> party DLLs folder under my source code
project.&nbsp; When this loads, it will attempt to load the other dependent
DLLs.&nbsp; Try that approach with your C# app to see if you can narrow the
problem.</span><o:p></o:p></p>

<p><span style='font-size:11.0pt;color:#1F497D'>&nbsp;</span><o:p></o:p></p>

<p><span style='font-size:11.0pt;color:#1F497D'>Brian</span><o:p></o:p></p>

<p><span style='font-size:11.0pt;color:#1F497D'>&nbsp;</span><o:p></o:p></p>

<div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'>

<p><b><span style='font-size:10.0pt'>From:</span></b><span style='font-size:
10.0pt'> Nelson Soto [mailto:<a href="mailto:nellyfromma@gmail.com"
target="_blank">nellyfromma@gmail.com</a>] <br>
<b>Sent:</b> Monday, August 25, 2008 8:48 AM<br>
<b>To:</b> Hulbert, Brian<br>
<b>Subject:</b> Re: [mapserver-users] MapServer and .NET?</span><o:p></o:p></p>

</div>

<div>

<div>

<p>&nbsp;<o:p></o:p></p>

<div>

<div>

<p>Thank you sir. Indeed you had a couple more dll's than I but still after
moving more over I receive the same error. I am trying to run a <a
href="http://vb.net/" target="_blank">vb.net</a> project but I also have a c#
one that produces the same error. The tutorial says I can use the mapscript.dll
and mapscript_csharp.dll that is in ms4w. Did you find that to be true or had
you compiled your own?<o:p></o:p></p>

</div>

<div>

<p>&nbsp;<o:p></o:p></p>

</div>

<div>

<p>Also, I think it's worth noting: I used the newest version of MS4W that
seems only weeks old... It now has a nice installer that allows you to specify
the installation path where previously it demanded to be installed in the root
ex: C:\ms4w or D:\ms4w... Since I was able to choose, I chose C:\program
files\ms4w.<o:p></o:p></p>

</div>

<div>

<p>&nbsp;<o:p></o:p></p>

</div>

<div>

<p style='margin-bottom:12.0pt'>Would this be an issue do you think?<o:p></o:p></p>

</div>

<div>

<p>On Mon, Aug 25, 2008 at 8:25 AM, Hulbert, Brian &lt;<a
href="mailto:brian.hulbert@linquest.com" target="_blank">brian.hulbert@linquest.com</a>&gt;
wrote:<o:p></o:p></p>

<div>

<div>

<p><span style='font-size:11.0pt;color:#1F497D'>I can't speak specifically to <a
href="http://asp.net/" target="_blank">ASP.NET</a> but for C#, I place all of
the MapScript-related DLLs in the same directory as my C# application
executable.&nbsp; Below are the files that I have in my Debug or Release folder
for MapServer 5.0.2</span><o:p></o:p></p>

<p><span style='font-size:11.0pt;color:#1F497D'>cfitsio.dll<br>
gdal15.dll<br>
geos_c.dll<br>
geotiff.dll<br>
hdf5dll.dll<br>
iconv.dll<br>
jbig1.dll<br>
libcurl.dll<br>
libeay32.dll<br>
libecwj2.dll<br>
libexpat.dll<br>
libfcgi.dll<br>
libmap.dll<br>
libmysql.dll<br>
libpq.dll<br>
libtiff.dll<br>
libxml2.dll<br>
lti_dsdk_dll.dll<br>
mapscript.dll<br>
mapscript_csharp.dll<br>
netcdf.dll<br>
pdflib.dll<br>
proj.dll<br>
sqlite3.dll<br>
ssleay32.dll<br>
szlibdll.dll<br>
xerces-c_2_7.dll<br>
zlib1.dll</span><o:p></o:p></p>

<p><span style='font-size:11.0pt;color:#1F497D'>HTH,</span><o:p></o:p></p>

<p><span style='font-size:11.0pt;color:#1F497D'>&nbsp;Brian</span><o:p></o:p></p>

<div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'>

<p><span style='font-size:11.0pt;color:#1F497D'>&nbsp;</span><b><span
style='font-size:10.0pt'>From:</span></b><span style='font-size:10.0pt'> <a
href="mailto:mapserver-users-bounces@lists.osgeo.org" target="_blank">mapserver-users-bounces@lists.osgeo.org</a>
[mailto:<a href="mailto:mapserver-users-bounces@lists.osgeo.org" target="_blank">mapserver-users-bounces@lists.osgeo.org</a>]
<b>On Behalf Of </b>Nelson Soto<br>
<b>Sent:</b> Monday, August 25, 2008 8:10 AM<br>
<b>To:</b> Mapserver-users<br>
<b>Subject:</b> [mapserver-users] MapServer and .NET?</span><o:p></o:p></p>

</div>

<div>

<div>

<div>

<div>

<p>&nbsp;Hi Guys,<o:p></o:p></p>

</div>

<div>

<p>&nbsp;I am following the tutorial on <a
href="http://www.paolocorti.net/2006/09/20/mapserver-tutorial-for-c-mapscript-asp-net/"
target="_blank">http://www.paolocorti.net/2006/09/20/mapserver-tutorial-for-c-mapscript-asp-net/</a>&nbsp;regarding
getting started with MapServer on .Net. I eventually hit a snag where I run
into error &quot;The type initializer for 'OSGeo.MapServer.mapscriptPINVOKE'
threw an exception&quot; when trying to run the demo application. I have tried
several demo projects in Visual Studio and I receive the same errors. Running
down the stack, this seems to be the general exception:<o:p></o:p></p>

</div>

<div>

<p>&nbsp;&nbsp;{&quot;Unable to load DLL 'mapscript': The specified module
could not be found. (Exception from HRESULT: 0x8007007E)&quot;}<o:p></o:p></p>

</div>

<div>

<p>&nbsp;This happens even with projects that are coming with there own
mapserver.dll and all other necessary filesinthe bin folder. Does anyone have
any experience with dealing with MapServer on .Net and can anyone help me or
point me in the right direction. Right now I guess I am looking at downloading
Dependancy Walker to try to see if I can get further into this exception, but I
just want to know if anyone else has ever run into this before.<o:p></o:p></p>

</div>

<div>

<p>&nbsp;Thanks,<o:p></o:p></p>

</div>

<div>

<p>Nelson Soto<o:p></o:p></p>

</div>

</div>

</div>

</div>

</div>

</div>

</div>

</div>

</div>

</div>

</div>

</div>

</div>

<p class=MsoNormal><o:p>&nbsp;</o:p></p>

</div>

</div>

</body>

</html>