Skip to content

Latest commit

 

History

History
24 lines (17 loc) · 1.53 KB

webview_captureselectedcontenttodatapackageasync_1187796026.md

File metadata and controls

24 lines (17 loc) · 1.53 KB
-api-id -api-type
M:Windows.UI.Xaml.Controls.WebView.CaptureSelectedContentToDataPackageAsync
winrt method

Windows.UI.Xaml.Controls.WebView.CaptureSelectedContentToDataPackageAsync

-description

Asynchronously gets a DataPackage that contains the selected content within the WebView.

-returns

When this method completes, it returns the selected content as a DataPackage.

-remarks

You can use this method during a share operation to send the selected WebView content to a target app. This method is asynchronous, so you must use a deferral to prevent your DataRequested event handler from returning before the asynchronous call is complete. Call DataRequestedEventArgs.Request.GetDeferral to create the deferral and DataRequestDeferral.Complete to end it.

-examples

-see-also

DataPackage, WebView control (XAML) sample (Windows 10)