简体   繁体   中英

ASP.net Unable to load DLL 'Magick.NET-Q16-x64.Native.dll': Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED))

I am using image Magick to create images from Stream. I am getting the error mentioned in title on following lines.

 var image = new MagickImage();

It is an issue with ImageMagick or something else. Dont know how to solve this!!

Workaround: assign user to application pool identity with extra privileges.

Solution (worked for me)

  1. Manually set temp directory MagickNET.SetTempDirectory(@"C:\\Windows\\Temp\\");
  2. Give user of Application Pool Identity write permissions to it. In my case I've provided for "Users" group write permission.

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