Cannot Find HResult from WindowsAPICodePack

170 views Asked by At

I have been working on this for couple hours, searching everywhere can't couldn't find a solution.

I got an error message saying:

アセンブリ 'Microsoft.WindowsAPICodePack, Version=1.0.0.0, Culture=neutral, PublicKeyToken=null' から型 'MS.WindowsAPICodePack.Internal.HResult' を読み込めませんでした。

Which roughly translates into cannot read type blahblahblah.HResult from assembly blahblahblah.

I'm trying to get the thumbnail from a file, using ShellFile.FromFilePath(f.FullName).Thumbnail.ExtraLargeBitmap

The exception is thrown at .Thumbnail.

Any help to get me a transparent thumbnail would do, but I'm really looking for short answers.

1

There are 1 answers

0
Zuoanqh On

This problem is caused by me dragging the dll file directly into the project, apparently that .dll file, for some reason that does not have the class i needed was used instead of the reference. After removing the dll file everything works.