title: bool type equivalent for calling Unmanaged C++ API from C#
body: <p>I am getting <b><i>System.EntryPointNotFoundException</i></b> while calling an Unmanaged method (C++) from C# which takes 'bool' as argument.</p>
  
  <p>Following is the <b>function declaration in C++</b></p>
  
  <pre><code>__declspec(dllexport) void _stdcall MethodA(bool Flag);
  </code></pre>
  
  <p>I used the <b>following code in C#</b> which I found after searching for a while. But I still get the same exception. </p>
  
  <pre><code>[DllImport("UnmanagedDLL.dll")]
  private static extern void MethodA([MarshalAs(UnmanagedType.I1)] bool Flag);
  </code></pre>
  
  <p>I also tried using <i>Byte</i>, <i>Boolean</i> &amp; <i>int</i> types instead of bool, still i get same exception.</p>
  
  <p>Please someone give me a solution for my problem.</p>
  
  <p>Thanks in advance
  User2794477</p>