netcore 使用System.Drawing 出现如下错误:

Unhandled Exception: System.TypeInitializationException: The type initializer for 'Gdip' threw an exception. ---> System.DllNotFoundException: Unable to load DLL 'libgdiplus': The specified module could not be found.
at System.Runtime.InteropServices.FunctionWrapper`.get_Delegate()
at System.Drawing.SafeNativeMethods.Gdip.GdiplusStartup(IntPtr& token, StartupInput& input, StartupOutput& output)
at System.Drawing.SafeNativeMethods.Gdip..cctor()
--- End of inner exception stack trace ---
at System.Drawing.SafeNativeMethods.Gdip.GdipLoadImageFromFile(String filename, IntPtr& image)
at System.Drawing.Image.FromFile(String filename, Boolean useEmbeddedColorManagement)
at System.Drawing.Image.FromFile(String filename)

安装 libgdiplus

  同样的问题 https://github.com/dotnet/corefx/issues/25157

解决方法: https://q.cnblogs.com/q/103863/

解决方法: https://q.cnblogs.com/q/107946/

System.DllNotFoundException: Unable to load DLL 'libgdiplus': The specified module could not be found.的更多相关文章

  1. Unhandled Exception:System.DllNotFoundException: Unable to load DLL"**":找不到指定的模块

    在项目中使用C#代码调用C++ DLL时.常常会出现这个问题:在开发者自己的电脑上运行没有问题,但是部署到客户电脑上时会出现下面问题: Unhandled Exception:System.DllNo ...

  2. uwp - 解决使用EntityFramework时报错“unable to load dll 'sqlite3':the specified module could not be found”

    在使用uwp的ef过程中碰到一万个问题快折腾死我了,好在最后终于解决掉所有问题,但愿如此,因为在这之前先后发生不同的报错,不知道后面还会碰到新的问题不. 其中一个问题是这样的,生成能正常生成,但是启动 ...

  3. [ASP.NET 5]终于解决:Unable to load DLL 'api-ms-win-core-localization-obsolete-l1-2-0.dll'

    11月12日,惊喜地发现SqlClient(System.Data.SqlClient.dll)跨平台了(对应的nuget包包是runtime.unix.System.Data.SqlClient), ...

  4. Unable to load DLL 'opencv_core290'

    问题: In my winforms application I need to use some Emgu.CV libraries (I have installed Emgu 2.9). Pro ...

  5. Centos 7 Asp.net core 使用QRCoder 报“Unable to load DLL 'gdiplus'"

    环境: Centos7 .Net core 2.0 问题: 使用QRCoder 报“Unable to load DLL 'gdiplus'" 同 https://q.cnblogs.com ...

  6. SqlSugar解决SQLite访问的问题:Unable to load DLL 'SQLite.Interop.dll'

    SqlSugar用的版本是4.5.9.5,访问SQLite数据提示错误.在本机调试一时没有什么错误,把代码发布到服务器上以后刚开始运行没有问题,一段时间后报错. English Message : C ...

  7. Unable to load dll 的解决方案

    前几天在做项目时,需要用到一个非托管的 dll 库,其实使用 .Net 的互操作技术可以很方便地调用非托管 dll 文件中的函数,但是在执行时出现了“Unable to load dll HRESUL ...

  8. Unable to load DLL 'api-ms-win-core-localization-l1-2-0.dll': 找不到指定的模块

    asp.net mvc 4.6 发布到WinServer2008R2 SP1 提示 错误 Unable to load DLL 'api-ms-win-core-localization-l1-2-0 ...

  9. [转]System.DllNotFoundException: 无法加载 DLL“*.dll”: 内存位置访问无效。 (异常来自 HRESULT:0x800703E6)

    我在使用地税发票控件进行开票的测试的时候,在xp上测试时正常的,在别人的win7系统测试也是正常,但我在我本机确不正常.我本机装的是msdn版本win7系统,这个系统比较原装. 错误信息如下: -- ...

随机推荐

  1. 关于linux 共享内存查看已经完整释放

    完整删除共享内存脚本 #!/bin/sh function rmshm() { zero_status=`ipcs -m|awk '{print $6}'|grep -w 0|wc -l` if [ ...

  2. 一些面试题(关于string的)

    一些常见的面试题: String a = "hello2"; String b = "hello" + 2; System.out.println(a == b ...

  3. 初学node遇到的问题(慢慢补充)

    一.看到菜鸟教程的Web模块运行client.js的时候遇到报错: E:\node\server>node client.js events.js:72throw er; // Unhandle ...

  4. linux 路由表 的一些相关资料

    linux 路由表维护 查看 Linux 内核路由表 使用下面的 route 命令可以查看 Linux 内核路由表. # route Destination Gateway Genmask Flags ...

  5. mysql 数据库导出与导入

    1.数据库导出 语句:mysqldump -u用戶名 -p密码 -d 数据库名 表名 > 脚本名; 1.导出整个数据库结构和数据 mysqldump -h localhost -uroot -p ...

  6. MT4 取K线

    目标:动态获取最新K线并通过DLL发送出去,symbols和periods可配置. //+------------------------------------------------------- ...

  7. KeyguardSliceView.java

    /* * Copyright (C) 2017 The Android Open Source Project * * Licensed under the Apache License, Versi ...

  8. Python3.7 练习题(-) 如何使用Python生成200个优惠卷(激活码)

    # 如何使用Python生成200个优惠卷(激活码) import random import string # string.ascii_letters 26个大小写 # -9数字 # 获得激活码中 ...

  9. c# 获取某进程占用的内存(任务管理器显示的内存一致)

    最近写了看门狗的winform程序,需求要求显示监测的进程所占的内存大小 找了好几个方法,都和任务管理器显示的内存不一致 最后找到了一个解决方法 PerformanceCounter pf1 = ne ...

  10. JavaScript权威指南--第3章 类型、值和变量

    在编程语言中,能够表示并操作的值(value)的类型称作数据类型(type).使用变量来储存值.JavaScript中数据类型有两种:原始类型(primitive type/基本数据类型)和对象类型( ...