Created
October 20, 2022 08:14
-
-
Save dimonovdd/f4c7527d1fb11fa27c405e7576b1639c to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<body> | |
<script src="http://code.jquery.com/jquery-2.1.4.min.js"></script> | |
<h1>HybridWebView Test</h1> | |
<br /> | |
Enter name: <input type="text" id="name"> | |
<br /> | |
<br /> | |
<button type="button" onclick="javascript: invokeCSCode($('#name').val());">Invoke C# Code</button> | |
<br /> | |
<p id="result">Result:</p> | |
<script type="text/javascript">function log(str) { | |
$('#result').text($('#result').text() + " " + str); | |
} | |
function invokeCSCode(data) { | |
try { | |
log("Sending Data:" + data); | |
invokeCSharpAction(data); | |
} | |
catch (err) { | |
log(err); | |
} | |
}</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment