<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Yes, I verified them by in Intel® Fortran Compiler</title>
    <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Call-Fortran-DLL-from-NET/m-p/1064692#M118187</link>
    <description>&lt;P&gt;Yes, I verified them&amp;nbsp;by comparing them to the working install.&lt;/P&gt;</description>
    <pubDate>Tue, 10 Jan 2017 15:22:35 GMT</pubDate>
    <dc:creator>John_N</dc:creator>
    <dc:date>2017-01-10T15:22:35Z</dc:date>
    <item>
      <title>Call Fortran DLL from .NET</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Call-Fortran-DLL-from-NET/m-p/1064689#M118184</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;

&lt;P&gt;I just installed&amp;nbsp;Parallel Studio&amp;nbsp;XE for Windows.&amp;nbsp;I have tried to reference multiple Fortran DLLs from .NET.&amp;nbsp; The call doesn't toss any errors but the Fortran&amp;nbsp;DLL doesn't run.&amp;nbsp; This morning, I took a copy of a&amp;nbsp;test project and had a colleague run the same project and it worked successfully for him but it does nothing for me.&amp;nbsp; With one sample program I get an unable to load dll error.&amp;nbsp;I'm linking the dll as an existing item&amp;nbsp;(add by link).&amp;nbsp; Most just act like they will work and do nothing.&lt;/P&gt;

&lt;P&gt;I'm able to run the same code&amp;nbsp;by running it as a fortran exe instead on my machine.&amp;nbsp; We are both running VS 2015 enterprise and have the latest versions of&amp;nbsp;&amp;nbsp;Parallel Studio for Windows.&amp;nbsp; The only difference is I'm running Windows 10 and he is running Windows 7.&amp;nbsp; What could I be missing from a configuration standpoint to cause this issue.&amp;nbsp; Or is it a setup issue?&amp;nbsp; Or just Windows 10?&lt;/P&gt;

&lt;P&gt;Thanks in advance for the help,&lt;/P&gt;

&lt;P&gt;John&lt;/P&gt;</description>
      <pubDate>Mon, 09 Jan 2017 14:42:38 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Call-Fortran-DLL-from-NET/m-p/1064689#M118184</guid>
      <dc:creator>John_N</dc:creator>
      <dc:date>2017-01-09T14:42:38Z</dc:date>
    </item>
    <item>
      <title>Are the Fortran and C runtime</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Call-Fortran-DLL-from-NET/m-p/1064690#M118185</link>
      <description>&lt;P&gt;Are the Fortran and C runtime DLL's on your system path?&lt;/P&gt;</description>
      <pubDate>Tue, 10 Jan 2017 01:30:00 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Call-Fortran-DLL-from-NET/m-p/1064690#M118185</guid>
      <dc:creator>IanH</dc:creator>
      <dc:date>2017-01-10T01:30:00Z</dc:date>
    </item>
    <item>
      <title>Yes, I verified them by</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Call-Fortran-DLL-from-NET/m-p/1064691#M118186</link>
      <description>&lt;P&gt;Yes, I verified them&amp;nbsp;by comparing them to the working install.&lt;/P&gt;</description>
      <pubDate>Tue, 10 Jan 2017 15:14:27 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Call-Fortran-DLL-from-NET/m-p/1064691#M118186</guid>
      <dc:creator>John_N</dc:creator>
      <dc:date>2017-01-10T15:14:27Z</dc:date>
    </item>
    <item>
      <title>Yes, I verified them by</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Call-Fortran-DLL-from-NET/m-p/1064692#M118187</link>
      <description>&lt;P&gt;Yes, I verified them&amp;nbsp;by comparing them to the working install.&lt;/P&gt;</description>
      <pubDate>Tue, 10 Jan 2017 15:22:35 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Call-Fortran-DLL-from-NET/m-p/1064692#M118187</guid>
      <dc:creator>John_N</dc:creator>
      <dc:date>2017-01-10T15:22:35Z</dc:date>
    </item>
    <item>
      <title>Your approach with .NET</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Call-Fortran-DLL-from-NET/m-p/1064693#M118188</link>
      <description>&lt;P&gt;Your approach with .NET calling Fortran DLLs may be similar to mine. &amp;nbsp;Are you using C# or maybe VB? &amp;nbsp;I have a C# front end exe that calls Fortran DLLs. &amp;nbsp;I've had success by copying the Fortran DLLs into the C# projects /bin/x64/Debug folder, then running the C# exe from Visual Studio or directly at the exe. &amp;nbsp;&lt;/P&gt;

&lt;P&gt;In the C# class that calls the Fortran routines I have added syntax to identify the DLL name and subroutine name, and add the "InteropServices" class:&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="font-family: Consolas, &amp;quot;Lucida Console&amp;quot;, Menlo, Monaco, &amp;quot;DejaVu Sans Mono&amp;quot;, monospace, sans-serif; font-size: 1em;"&gt;using System.Runtime.InteropServices;&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;And in the C# method I also define each Fortran routine as a static external method with the DllImport attribute to name the DLL to help the exe locate it. &amp;nbsp;I have found that I can omit the ".dll" extension for the project name in DllImport, such as myFortProj.dll identified as "myFortProj" with subroutine "myFortSub":&lt;/P&gt;

&lt;PRE class="brush:csharp;"&gt;[DllImport("myFortProj")]
static extern void myFortSub(ref int value1, double[] array2);&lt;/PRE&gt;

&lt;P&gt;And then later in the C# method the "myFortSub" is called. &amp;nbsp;&lt;SPAN style="font-size: 1em;"&gt;Is this anything like what you are trying to do?&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;Regards,&lt;/P&gt;

&lt;P&gt;Greg T.&lt;/P&gt;</description>
      <pubDate>Tue, 10 Jan 2017 16:08:04 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Call-Fortran-DLL-from-NET/m-p/1064693#M118188</guid>
      <dc:creator>Greg_T_</dc:creator>
      <dc:date>2017-01-10T16:08:04Z</dc:date>
    </item>
    <item>
      <title>I'm using the VB.NET</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Call-Fortran-DLL-from-NET/m-p/1064694#M118189</link>
      <description>&lt;P&gt;I'm using the VB.NET equivalent, but yes, I have tried both the DllImport method and the Declare method.&amp;nbsp; Both dll call types&amp;nbsp;work, just not on my machine.&lt;/P&gt;</description>
      <pubDate>Tue, 10 Jan 2017 16:27:28 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Call-Fortran-DLL-from-NET/m-p/1064694#M118189</guid>
      <dc:creator>John_N</dc:creator>
      <dc:date>2017-01-10T16:27:28Z</dc:date>
    </item>
    <item>
      <title>I'm using the VB.NET</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Call-Fortran-DLL-from-NET/m-p/1064695#M118190</link>
      <description>&lt;P&gt;I'm using the VB.NET equivalent, but yes, I have tried both the DllImport method and the Declare method.&amp;nbsp; Both dll call types&amp;nbsp;work, just not on my machine.&lt;/P&gt;</description>
      <pubDate>Tue, 10 Jan 2017 16:29:18 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Call-Fortran-DLL-from-NET/m-p/1064695#M118190</guid>
      <dc:creator>John_N</dc:creator>
      <dc:date>2017-01-10T16:29:18Z</dc:date>
    </item>
    <item>
      <title>Quote:John N wrote:</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/Call-Fortran-DLL-from-NET/m-p/1064696#M118191</link>
      <description>&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;John N wrote:&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;

&lt;P&gt;.. Both dll call types&amp;nbsp;work, just not on my machine.&lt;/P&gt;

&lt;P&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;

&lt;P&gt;@John N,&lt;/P&gt;

&lt;P&gt;Have you checked the dependencies of the DLL(s) in question using a tool such as &lt;STRONG&gt;&lt;A href="http://www.dependencywalker.com/"&gt;Dependency Walker&lt;/A&gt;&lt;/STRONG&gt; and confirmed the files are all present on your system?&lt;/P&gt;</description>
      <pubDate>Tue, 10 Jan 2017 20:29:05 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/Call-Fortran-DLL-from-NET/m-p/1064696#M118191</guid>
      <dc:creator>FortranFan</dc:creator>
      <dc:date>2017-01-10T20:29:05Z</dc:date>
    </item>
  </channel>
</rss>

