I have a straightforward JS function that returns a value. It's all working in the WKWebView. However, Result just returns Null in the JSComplete event. How can I get the return value from my JS function to the Result parameter in that function?
WKWebView1.EvaluateJavaScript("", $"
x = 100;
y = 100;
x + y;
"$)
Wait For wkWebView1_JSComplete (Success As Boolean, Tag As Object, Result As String)
If Success Then
Log(Result)
End If
I didn't know you could use a Wait For. Hopefully that'll do it because the Javascript I'm executing does in fact have to wait for the web to return the data.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.