Hi Marten,
Please the example below on how to do this in VAST 14 (or earlier).
Indeed, the webview needs to be initialized before it can be interacted with.
Because this happens asynchronously, one needs to wait a while, which comes ’naturally’ in the example that is provided in the documentation and code right now.
For the upcoming VAST 15, we have improved the WebView2 API such that the last 2 statements in this example can be replaced with `webView whenReadyDo: [ webView setUrl: '
https://www.instantiations.com/']`.
Hope this helps!
----
shell := CwTopLevelShell
createApplicationShell: 'shell'
argBlock: [:w | w title: 'Web View Demo'].
webView := CwWebView createWidget: 'WebView'
parent: shell argBlock: [:w | w
borderWidth: 1;
width: 1280;
height: 1040 ].
webView manageChild.
shell realizeWidget.
CwAppContext default readAndDispatchWhile:[ webView osWidget webView isNil ].
|
Johan Brichau
VAST Consultant
Senior Software Engineer
|
|
|
|
|
|
|
|
|
|