2013-04-27 78 views
0

我已經下載並安裝手冊中所述的Microsoft Accelerator,但是當我嘗試創建使用open Microsoft.ParallelArrays的項目時,ParallelArrays仍未定義。微軟加速器庫與Visual Studio F#

我試着通過參考將加速器添加到列表中,但似乎無法找到它。

我在做什麼錯?

編輯:

我發現在不工作的另一個位置的文件,但是當我編譯和運行我的測試程序,它拋出的錯誤

Unhandled Exception: System.DllNotFoundException: Unable to load DLL 'Accelerato 
r.dll': The specified module could not be found. (Exception from HRESULT: 0x8007 
007E) 
    at Microsoft.ParallelArrays.FloatParallelArray.AcceleratorNative.Create_FPA_F 
A1D(Single[] values, IntPtr Length) 
    at Microsoft.ParallelArrays.FloatParallelArray..ctor(Single[] values) 
    at Program.Test1() in c:\users\misao\documents\visual studio 2012\Projects\ac 
celeratortest\acceleratortest\Program.fs:line 10 
    at <StartupCode$acceleratortest>[email protected]() in c:\users\misao\documents 
\visual studio 2012\Projects\acceleratortest\acceleratortest\Program.fs:line 97 
Press any key to continue . . . 
+0

您是否這樣做 - 添加一個對System.Drawing的引用和受管理的Microsoft.Accelerator.dll(在您的目標的適當目錄下,例如C:\ Program Files文件(x86)\ Microsoft \ Accelerator v2 \ bin \ Managed \發佈\ Microsoft.Accelerator.dll – 2013-04-27 01:33:53

+0

對不起,我對VS有點新,我該如何添加一個C:\路徑作爲參考? – misaochan 2013-04-27 01:39:09

+0

參考 - >添加引用 - >瀏覽 - >瀏覽 – 2013-04-27 01:41:01

回答

-1

最簡單的方法是複製的DLL在您的可執行文件目錄仍然是最好的方式,使其工作沒有問題給你,尤其是避免可怕的後:「System.DllNotFoundException:無法加載DLL'Accelerato r.dll'」

1

添加dll' Accelerator.dll'來喲你的項目。 右鍵單擊該項目,添加/現有項目。 然後將此文件的「複製到輸出」屬性設置爲「始終複製」。