title: VB.NET to C++/CLI: How do I import a VB.NET DLL file into C++/CLI?
body: <p>I would like to import a VB.NET DLL file into C++/CLI. I am having trouble referencing my DLL file. I have tried to find tutorials but with no luck, in particular, I usually find how to import managed libraries directly into native code through COM. I would like to import an existing VB.NET DLL file into my C++/CLI project. </p>
  
  <p>Do I require a header file or a declaration file to import and use my VB.NET DLL file?</p>
  
  <p><strong>Foo.vb</strong></p>
  
  <pre><code>Public Module Foo
      Public Function Bar(ByVal a As Integer, ByVal b As Integer) As Boolean
          Return a &gt; b
      End Function
  End Module
  </code></pre>
  
  <p><strong>Mixed.cpp</strong></p>
  
  <pre><code>#include "stdafx.h"
  #using "..\Foo\bin\Debug\Foo.dll"
  using namespace System;
  
  int main(array&lt;System::String ^&gt; ^args)
  {
      bool i = Foo::Bar(10,1);
      Console::WriteLine(i);
      return 0;
  }
  </code></pre>