How do I use a free library, such as Html Agility in my Visual Studio Express C# programs? Obviously I have downloaded it. What I need to know is how do I set it up so I can simply use a "using" statement to link up with the classes. Html Agility does not come with any .dll's so do I need to compile it to dll, and then reference to that dll?
如何在Visual Studio Express C#程序中使用免费库,例如Html Agility?显然我已经下载了它。我需要知道的是如何设置它以便我可以简单地使用“using”语句来链接类。 Html Agility不带任何.dll所以我需要将它编译为dll,然后引用该dll?
If so, how do you compile to dll in Visual Studio Express?
如果是这样,如何在Visual Studio Express中编译为dll?
2 个解决方案
#1
Since you don't have any binaries with the downloaded thing, this means that what you have got is the source code. So, you should know that which type of code is this. Is this a .NET code? (if it is so, it should have a .csproj or a .vbproj etc file with it.) Then again it depends that with which development environment it was built with. If it is a project of Visusl Studio Express than you can build the project in your Visual Studio Express edition, otherwise, I am afraid that you would not be able to do so.
由于下载的东西没有任何二进制文件,这意味着你得到的是源代码。所以,您应该知道这是哪种类型的代码。这是一个.NET代码吗? (如果是这样的话,它应该有一个.csproj或.vbproj等文件。)然后再取决于它与它构建的开发环境。如果它是Visusl Studio Express的项目,那么您可以在Visual Studio Express版本中构建项目,否则,我担心您将无法这样做。
The best thing is that you should download the binaries (dlls etc) and use them in your project by adding reference as you mentioned. Otherwise, you are left with two options. Either to build the code and make a binary or to use the code directly but for that you need to have a thorough understanding of the code.
最好的是你应该下载二进制文件(dll等)并在你的项目中使用它们,如你所提到的那样添加引用。否则,你有两个选择。要么构建代码并制作二进制文件,要么直接使用代码,但为此需要彻底了解代码。
#2
I think this link to msdn might work:
我认为msdn的这个链接可能有用:
Basically, create the dll using 'Build' then link to the reference.
基本上,使用'Build'创建dll然后链接到引用。
#1
Since you don't have any binaries with the downloaded thing, this means that what you have got is the source code. So, you should know that which type of code is this. Is this a .NET code? (if it is so, it should have a .csproj or a .vbproj etc file with it.) Then again it depends that with which development environment it was built with. If it is a project of Visusl Studio Express than you can build the project in your Visual Studio Express edition, otherwise, I am afraid that you would not be able to do so.
由于下载的东西没有任何二进制文件,这意味着你得到的是源代码。所以,您应该知道这是哪种类型的代码。这是一个.NET代码吗? (如果是这样的话,它应该有一个.csproj或.vbproj等文件。)然后再取决于它与它构建的开发环境。如果它是Visusl Studio Express的项目,那么您可以在Visual Studio Express版本中构建项目,否则,我担心您将无法这样做。
The best thing is that you should download the binaries (dlls etc) and use them in your project by adding reference as you mentioned. Otherwise, you are left with two options. Either to build the code and make a binary or to use the code directly but for that you need to have a thorough understanding of the code.
最好的是你应该下载二进制文件(dll等)并在你的项目中使用它们,如你所提到的那样添加引用。否则,你有两个选择。要么构建代码并制作二进制文件,要么直接使用代码,但为此需要彻底了解代码。
#2
I think this link to msdn might work:
我认为msdn的这个链接可能有用:
Basically, create the dll using 'Build' then link to the reference.
基本上,使用'Build'创建dll然后链接到引用。