Platforms to show: All Mac Windows Linux Cross-Platform

WKWebViewControlMBS control

See also desktop control: DesktopWKWebViewControlMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
control WebKit2 MBS Mac64bit Plugin 16.4 ✅ Yes ❌ No ❌ No ❌ No Desktop only
A WKWebView object displays interactive web content, such as for an in-app browser.
Example
// print a WKWebViewControlMBS to PDF file:

Var browser as WKWebViewControlMBS // your control showing website
Var pi As NSPrintInfoMBS = NSPrintInfoMBS.sharedPrintInfo

Var f As FolderItem = SpecialFolder.Desktop.Child("test.pdf")
pi.SetSaveDestination f

Var po As NSPrintOperationMBS = browser.printOperation(pi)

po.showsPrintPanel = False
po.showsProgressPanel = False

If po.runOperation Then
f.launch
End If

This is a control to use WebKit in 32-bit and WebKit 2 in 64-bit.
Most of the events provided by Xojo for the control will not work.
But we can add features over time as needed.
Let us know if you need a method from WKWebView or an event from WKNavigationDelegate or WKUIDelegate.

Authentication Challenge Responses

Constant Value Description
AuthChallengeCancelAuthenticationChallenge 2 Cancel the entire request. The provided credential parameter is ignored.
AuthChallengePerformDefaultHandling 1 Use the default handling for the challenge as though this delegate method were not implemented. The provided credential parameter is ignored.
AuthChallengeRejectProtectionSpace 3 Reject this challenge, and call the authentication delegate method again with the next authentication protection space. The provided credential parameter is ignored.
AuthChallengeUseCredential 0 Use the specified credential, which may be nil.

Redirect Policy

Constant Value Description
DownloadRedirectPolicyAllow 1 Allow a redirect to proceed.
DownloadRedirectPolicyCancel 0 Cancel the redirect action.

Some examples using this control:

Blog Entries

Xojo Developer Magazine

Videos

Release notes


The items on this page are in the following plugins: MBS Mac64bit Plugin.


WinPreviewControlMBS   -   WKWebViewIOSControlMBS


The biggest plugin in space...