简体   繁体   中英

How Do I Get External LIbrary Like Html Agility To Work In My C# Project?

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?

If so, how do you compile to dll in Visual Studio Express?

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.

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.

I think this link to msdn might work:

Basically, create the dll using 'Build' then link to the reference.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM