WebView Class
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Caution
The WebView control will be replaced by WebView2 in the future. Read more at https://aka.ms/webview2
This class is an implementation of IWebView for WPF. This class cannot be inherited.
[System.Obsolete("The WebView control will be replaced by WebView2 in the future. Read more at https://aka.ms/webview2")]
public sealed class WebView : Microsoft.Toolkit.Wpf.UI.Controls.WebViewHost, Microsoft.Toolkit.UI.Controls.IWebViewCompatible, Microsoft.Toolkit.Win32.UI.Controls.IWebView
[<System.Obsolete("The WebView control will be replaced by WebView2 in the future. Read more at https://aka.ms/webview2")>]
type WebView = class
inherit WebViewHost
interface IWebView
interface IWebViewCompatible
Public NotInheritable Class WebView
Inherits WebViewHost
Implements IWebView, IWebViewCompatible
- Inheritance
- Attributes
- Implements
Web |
Initializes a new instance of the WebView class. |
Web |
Can |
Gets a value indicating whether there is at least one page in the backward navigation history. |
Can |
Gets a value indicating whether there is at least one page in the forward navigation history. |
Child |
Gets the child window. (Inherited from WebViewHost) |
Contains |
Gets a value indicating whether IWebView contains an element that supports full screen. |
Device |
Obsolete.
Gets the current DPI for this control (Inherited from WebViewHost) |
Document |
Gets the title of the page currently displayed in the IWebView. |
Dpi |
Gets the DPI information for which the Visual is measured and rendered. (Inherited from WebViewHost) |
Enterprise |
Gets or sets an enterprise ID for this process. |
Is |
Gets or sets a value indicating whether the use of IndexedDB is allowed. |
Is |
Gets or sets a value indicating whether the use of JavaScript is allowed. |
Is |
Gets or sets a value indicating whether the IsPrivateNetworkClientServerCapabilityEnabled |
Is |
Obsolete.
Gets a value indicating whether scaling is required for the current DPI. (Inherited from WebViewHost) |
Is |
Gets or sets a value indicating whether ScriptNotify is allowed. |
Is |
Gets a value indicating whether WebView is supported in this environment. |
Is |
Gets or sets a value indicating whether this instance is web view visible. |
Parent |
Gets the parent handle. (Inherited from WebViewHost) |
Process |
Gets the WebViewControlProcess that the control is hosted in. |
Settings |
Gets a WebViewControlSettings object that contains properties to enable or disable IWebView features. |
Source |
Gets or sets the Uniform Resource Identifier (URI) source of the HTML content to display in the IWebView. |
Version |
Gets the version of EDGEHTML.DLL used by IWebView. |
Add |
Adds the script to be loaded before any others on the page. |
Add |
Obsolete.
Adds the script to be loaded before any others on the page. |
Begin |
Starts the initialization process for this element. |
Build |
When overridden in a derived class, creates the window to be hosted. (Inherited from WebViewHost) |
Close() |
Closes this instance. |
Destroy |
Destroys the hosted window. (Inherited from WebViewHost) |
Dispose(Boolean) |
Immediately frees any system resources that the WebViewHost might hold. (Inherited from WebViewHost) |
End |
Indicates that the initialization process for the element is complete. |
Get |
Gets the deferred permission request with the specified Id. |
Go |
Navigates the IWebView to the previous page in the navigation history. |
Go |
Navigates the IWebView to the next page in the navigation history. |
Initialize() |
Initializes this instance. (Inherited from WebViewHost) |
Invoke |
Executes the specified script function from the currently loaded HTML, with no arguments, as a synchronous action. |
Invoke |
Executes the specified script function from the currently loaded HTML, with no arguments, as a synchronous action. |
Invoke |
Executes the specified script function from the currently loaded HTML, with no arguments, as a synchronous action. |
Invoke |
Executes the specified script function from the currently loaded HTML, with no arguments, as an asynchronous action. |
Invoke |
Executes the specified script function from the currently loaded HTML, with no arguments, as an asynchronous action. |
Invoke |
Executes the specified script function from the currently loaded HTML, with no arguments, as an asynchronous action. |
Move |
Moves the focus. |
Navigate(String) |
Loads the HTML content at the specified Uniform Resource Identifier (URI). |
Navigate(Uri, Http |
Navigates the web view with the URI with a HTTP request and HTTP headers. |
Navigate(Uri) |
Loads the HTML content at the specified Uniform Resource Identifier (URI). |
Navigate |
Obsolete.
Loads the specified HTML content relative to the location of the current executable. |
Navigate |
Loads local web content at the specified Uniform Resource Identifier (URI) using an IUriToStreamResolver. |
Navigate |
Loads the specified HTML content as a new document. |
Refresh() | |
Stop() |
Halts the current IWebView navigation or download. |
Translate |
Processes keyboard input at the keydown message level. (Inherited from WebViewHost) |
Update |
Updates the location and size of WebViewHost. (Inherited from WebViewHost) |
Update |
Updates the size of the WebViewHost using the current visual offset for location. (Inherited from WebViewHost) |
Wnd |
When overridden in a derived class, accesses the window process (handle) of the hosted child window. (Inherited from WebViewHost) |
Accelerator |
An event that is triggered when the accelerator key is pressed. |
Contains |
Occurs when the status of whether the IWebView currently contains a full screen element or not changes. |
Content |
Occurs when the IWebView has started loading new content. |
DOMContent |
Occurs when the IWebView finished parsing the current content. |
Frame |
Occurs when a frame in the IWebView has started loading new content. |
Frame |
Occurs when a frame in the IWebView finished parsing its current content. |
Frame |
Occurs when a frame in the IWebView finished navigating to new content. |
Frame |
Occurs when a frame in the IWebView navigates to new content. |
Long |
Occurs periodically while the IWebView executes JavaScript, letting you halt the script. |
Move |
Occurs when a focus move is requested. |
Navigation |
Occurs when the IWebView control finished navigating to new content. |
Navigation |
Occurs before the IWebView navigates to new content. |
New |
Occurs when an action is performed that causes content to be opened in a new window. |
Permission |
Occurs when an action in a IWebView requires that permission be granted. |
Script |
Occurs when the content contained in the IWebView control passes a string to the application by using JavaScript. |
Unsafe |
Occurs when IWebView shows a warning page for content that was reported as unsafe by SmartScreen filter. |
Unsupported |
Occurs when an attempt is made to navigate to a Source using a scheme that IWebView does not support. |
Unviewable |
Occurs when IWebView attempts to navigate to a content type it cannot render. Like other navigation events, it is only triggered by top level navigations. |
Producto | Versiones (Obsoleto) |
---|---|
Windows Community Toolkit | (6.1.1) |