Kasper Hansen
Kasper Hansen

Reputation: 6557

Cannot add HtmlAgilityPack as a reference

This shouldn't be difficult, but I can't add HtmlAgilityPack.dll as a reference in an empty C# project. Here is what I did:

  1. Downloaded HtmlAgilityPack.1.4.5.zip.
  2. Unzipped it.
  3. In the Solution Explorer, I right-clicked on References and selected 'Add Reference...'.
  4. I use Visual Studio 2008 and selected Net20/HtmlAgilityPack.dll.

There is now a yellow triangle on the HtmlAgilityPack.dll and I can't edit the path in its properties. If I remove it and add it again, the same thing happens. What am I doing wrong?

Upvotes: 0

Views: 3835

Answers (1)

Bruno Costa
Bruno Costa

Reputation: 2720

I had the same problem with 1.4.5, try to download the 1.4.0 version.

http://htmlagilitypack.codeplex.com/releases/view/44954

I'm not sure why it doesn't work, but if you look at here you will see others with the same problem.

Quoting ttraguth:

Hi,

I have the same problem here integrating the current 1.45 binaries in an .NET 3.5 Application.

dotPeek also shows the assembly as 4.0.

Maybe your .targets broke?

Upvotes: 1

Related Questions