"Unable to load DLL ..... Invalid access to memory location" error
<p>I am using a third party .dll (<a href="http://www.soft.tahionic.com/" rel="nofollow">from this website</a>) which generates Hardware ID. I am using it as per the <a href="http://www.soft.tahionic.com/download-hdd_id/hardware%20id%20programming%20source%20code/how%20to%20call%20it.html#dotnet_C#" rel="nofollow">direction</a> provided on that site. </p>

<pre><code>    [DllImport("HardwareIDExtractorC.dll")]
    public static extern String GetIDESerialNumber(byte DriveNumber);

    private void btnGetHardwareId_Click(object sender, EventArgs e)
    {

        MessageBox.Show(GetIDESerialNumber(0));
    }
</code></pre>

<p>But it is raising the following error-</p>

<p>Unable to load DLL 'HardwareIDExtractorC.dll': Invalid access to memory location. (Exception from HRESULT: 0x800703E6)</p>

<p>Am i missing anything here?</p>
