如何将 FreeImage.dll 添加到 C# 项目 [英] How to add FreeImage.dll to C# project
问题描述
我已经通过这种方式成功地将其他 .dll 文件添加到其他 C# 项目中:
I have successfully added other .dll files to other C# project this way:
右击参考>添加参考 >浏览 >双击 .dll 文件
但 Microsoft Visual Studio 2008 发出以下投诉:
but Microsoft Visual Studio 2008 issues the following complaint:
无法添加对 ...\dll\FreeImage.dll 的引用.请确保文件可访问,并且它是一个有效的程序集或 COM 组件.
我使用的是 .NET Framework 3.5.我相信这是一个 32 位的 dll(它是用 FreeImage3151Win32 下载的)所以我将项目的配置更改为 x86.
I am using .NET Framework 3.5. I believe this is a 32bit dll (it downloaded with FreeImage3151Win32) so I changed the configuration of the project to x86.
将 FreeImage.dll 添加到 C# 项目的正确方法是什么?
What is the correct method to add FreeImage.dll to a C# project?
推荐答案
使用下载中提供的 wrapper
.\Wrapper\FreeImage.NET\cs\Samples
目录中有 C# 示例.
Use the wrapper
provided in the download. There are C# samples in the \Wrapper\FreeImage.NET\cs\Samples
directory.
这篇关于如何将 FreeImage.dll 添加到 C# 项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!