Share via


CoreWebView2Environment.CreateCoreWebView2CompositionControllerWithOptionsAsync Method

Definition

Create a new webview in visual hosting mode with CoreWebView2ControllerOptions as parameter for multiple profiles support.

public System.Threading.Tasks.Task<Microsoft.Web.WebView2.Core.CoreWebView2CompositionController> CreateCoreWebView2CompositionControllerWithOptionsAsync (IntPtr ParentWindow, Microsoft.Web.WebView2.Core.CoreWebView2ControllerOptions options);
member this.CreateCoreWebView2CompositionControllerWithOptionsAsync : nativeint * Microsoft.Web.WebView2.Core.CoreWebView2ControllerOptions -> System.Threading.Tasks.Task<Microsoft.Web.WebView2.Core.CoreWebView2CompositionController>
Public Function CreateCoreWebView2CompositionControllerWithOptionsAsync (ParentWindow As IntPtr, options As CoreWebView2ControllerOptions) As Task(Of CoreWebView2CompositionController)

Parameters

ParentWindow
IntPtr

nativeint

The parent window of the WebView.

Returns

A completed handler that would be called when a new webview created in visual hosting mode.

Remarks

If a new webview has been created, the Task<TResult> will be immediately invoked.

Applies to