I spent a lot of time to figure out how to use VarSet function for my Lvar.
Since I have no results and spent too much time already I need your help...
Variable : L:MyVar,number
How to set value for L:MyVar,number using JavaScript VarSet ?
Something like?
Code: Select all
<!DOCTYPE html>
<html>
<body style="background-color:powderblue;">
<h2>JavaScript Variables</h2>
<p>Set/Read a variable and display it:</p>
<p id="value"></p>
<script>
function loop(timestamp)
{
VarSet("L:MyVar","number",5);
var value = VarGet("L:MyVar", "number");
document.getElementById('value').innerHTML = value;
window.requestAnimationFrame(loop);
}
window.requestAnimationFrame(loop);
</script>
</body>
</html>