Quantcast
Channel: htmlagilitypack Forum Rss Feed
Viewing all articles
Browse latest Browse all 655

New Post: Add-Type htmlagilitypack.dll fails - help?

$
0
0
I've tried doing add-type .\htmlagilitypack.dll with powershell v2 and powershell v3 but continue to get the below error. I've also tried loading the DLL from the net20, net40-client, and net45 folders. All produce the below error.

PS D:\htmlagilitypack\net40> Add-Type .\HtmlAgilityPack.dll
Add-Type : c:\Users\XXXX\AppData\Local\Temp\bww4lrx3.0.cs(1) : Unexpected character '\'
c:\Users\XXXX\AppData\Local\Temp\bww4lrx3.0.cs(1) : >>> .\HtmlAgilityPack.dll
At line:1 char:1
  • Add-Type .\HtmlAgilityPack.dll
  • ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    • CategoryInfo : InvalidData: (c:\Users...d character '\':CompilerError) [Add-Type], Exception
    • FullyQualifiedErrorId : SOURCE_CODE_ERROR,Microsoft.PowerShell.Commands.AddTypeCommand
Add-Type : c:\Users\XXXX\AppData\Local\Temp\bww4lrx3.0.cs(1) : A namespace cannot directly contain members such
as fields or methods
c:\Users\XXXX\AppData\Local\Temp\bww4lrx3.0.cs(1) : >>> .\HtmlAgilityPack.dll
At line:1 char:1
  • Add-Type .\HtmlAgilityPack.dll
  • ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    • CategoryInfo : InvalidData: (c:\Users..elds or methods:CompilerError) [Add-Type], Exception
    • FullyQualifiedErrorId : SOURCE_CODE_ERROR,Microsoft.PowerShell.Commands.AddTypeCommand
Add-Type : Cannot add type. There were compilation errors.
At line:1 char:1
  • Add-Type .\HtmlAgilityPack.dll
  • ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    • CategoryInfo : InvalidData: (:) [Add-Type], InvalidOperationException
    • FullyQualifiedErrorId : COMPILER_ERRORS,Microsoft.PowerShell.Commands.AddTypeCommand

Viewing all articles
Browse latest Browse all 655

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>