Add new Microsoft Edge to web browser control?(将新的 Microsoft Edge 添加到 Web 浏览器控件?)
问题描述
带有 Microsoft Edge 的新 Windows 10 已经到来.我想问你,我怎样才能将它添加到我的网络浏览器控件中?我需要它,因为实际的 Web 浏览器控件不允许 JavaScript 和 CSS3.
The new Windows 10 with Microsoft Edge has arrived. I want to ask you, how can I add it to my web browser control? I need it because the actual web browser control doesn't allow JavaScript and CSS3.
我曾经也添加了带有项目 WebKit 和 Awesomium 的 Chrome 浏览器,但他们不记得登录凭据(我的应用程序需要它们)所以我必须使用 I.E.不幸的是.
I used to also add Chrome browser with the projects WebKit and Awesomium but they didn't remember the login credentials (I need them for my app) so I have to use I.E. unfortunately.
推荐答案
2021 年 1 月更新:WebView2 已发布.这可以将基于 Chromium 的 Edge 集成为 Web 控件.不幸的是,它使用起来要复杂得多,但功能要强大得多.适用于 WinForms 或 WPF 或 C++ 应用程序.https://docs.microsoft.com/en-us/microsoft-edge/webview2/
UPDATE Jan 2021: WebView2 has been released. This enables integration of the Chromium based Edge as a web control. It's a lot more complicated to use, unfortunately, but a lot more powerful. Works with WinForms or WPF or C++ apps. https://docs.microsoft.com/en-us/microsoft-edge/webview2/
2018 年 5 月更新:微软终于让它变得简单了.https://blogs.windows.com/msedgedev/2018/05/09/modern-webview-winforms-wpf-apps/
UPDATE May 2018: FINALLY Microsoft has made it easy. https://blogs.windows.com/msedgedev/2018/05/09/modern-webview-winforms-wpf-apps/
目前,新控件位于 Windows Community Toolkit 3.0 中并包含在 Toolkit.Win32.UI.Controls.dll 中,您可能需要手动添加对其的引用.
For now, the new control is in the Windows Community Toolkit 3.0 and contained in Toolkit.Win32.UI.Controls.dll, which you may need to manually add a reference to.
======我希望有人提到这一点,所以我会添加它,因为它看起来不会更新 webbrowser 控件.
====== I wish somebody had mentioned this, so I'll add this because it doesn't look like webbrowser control will ever be updated.
改用 WebView 控件.这使用了 EdgeHTML 渲染引擎.这是 WindowPresentation 层的一部分但可以从 WinForms 和可能的其他应用程序链接.您必须转换为 UWP 应用程序
Use the WebView control instead. This uses EdgeHTML rendering engine. This is part of WindowPresentation layer but it is possible to link from WinForms and presumably other apps. You must convert to a UWP app
import Windows.UI.Xaml.Controls.WebView
示例代码:https://code.msdn.microsoft.com/windowsapps/XAML-WebView-control-sample-58ad63f7
我还没有用 WebView 替换我的 WebBrowser,但是界面看起来很熟悉.
I haven't replaced my WebBrowser with WebView yet, but the interface looks pretty familiar.
这篇关于将新的 Microsoft Edge 添加到 Web 浏览器控件?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:将新的 Microsoft Edge 添加到 Web 浏览器控件?
基础教程推荐
- 有没有办法忽略 2GB 文件上传的 maxRequestLength 限制? 2022-01-01
- SSE 浮点算术是否可重现? 2022-01-01
- 将 Office 安装到 Windows 容器 (servercore:ltsc2019) 失败,错误代码为 17002 2022-01-01
- rabbitmq 的 REST API 2022-01-01
- MS Visual Studio .NET 的替代品 2022-01-01
- 将 XML 转换为通用列表 2022-01-01
- c# Math.Sqrt 实现 2022-01-01
- 如何激活MC67中的红灯 2022-01-01
- 如何在 IDE 中获取 Xamarin Studio C# 输出? 2022-01-01
- 为什么Flurl.Http DownloadFileAsync/Http客户端GetAsync需要 2022-09-30