c# - Windows XP/Server 2003/VS 2010 上的 CefSharp

标签 c# .net visual-studio-2010 gac cefsharp

我正在尝试将 CefSharp 集成到我在 Windows XP 上的 Visual Studio 2010 中开发的 C# 项目中。其他运行 Windows Server 2003 的人也报告过类似的错误。

  1. 我通过 NuGet 添加 CefSharp.WinForms,它似乎运行良好。

  2. 我编译并运行该应用程序,但是当我尝试加载 CefSharp 时,我得到“无法加载由‘CefSharp.Core.dll’导入的过程。”

下面是我运行的代码:

        var settings = new CefSharp.CefSettings {
            PackLoadingDisabled = true
        };

        if (Cef.Initialize(settings)) {
            throw new Exception("Failed to initialze CefSharp");
        }

        var browser = new CefSharp.WinForms.ChromiumWebBrowser("http://www.google.com/");
        browser.SetBounds(0, 0, ClientSize.Width, ClientSize.Height);
        Controls.Add(browser);

关于CefSharp FAQ它告诉我,我应该执行一些我已经完成的任务,以便在 Windows XP 上运行,即使 XP 没有得到官方支持,它在常见问题解答中说它可以工作。

Error message that appears

Project files

Files in bin\x86\debug

最佳答案

我认为“确保安装了正确的 Visual C++ 版本”中有错别字/遗漏了一个词。

恕我直言,它应该是:“确保安装了正确的 Visual C++ 可再发行 版本。”

这是对另一个常见问题解答项目的引用: https://github.com/cefsharp/CefSharp/wiki/Frequently-asked-questions#Including_vcredist

关于c# - Windows XP/Server 2003/VS 2010 上的 CefSharp,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/28106861/

相关文章:

c# - Automapper 异常 : "Missing type map configuration or unsupported mapping."

C#:在字符串属性 setter 中调用方法时出现问题

c# - 使用 WinRT 文件夹选择器仅显示文件夹

c# - 如何在 HTML 中向现有表格添加新行

.net - 没有安装Visual Studio的应用程序崩溃

c++ - 在 vs 2010 中运行 c++ 单元测试时出现异常

c# - 我可以使用无键实体类型在 Entity Framework Core 中查询 CHANGETABLE 吗?

c# - ElasticSearch + NEST批量搜索

c# - 如何检测 BindingList<T> 中项目属性的更改?

c++ - 使用 C++ (VS 2010) FAST 将 BMP 保存为 PNG