I have this little script, that starts RealVNC viewer. This works fine, but I would like to send a variable to function. So the vncviewer.exe should start with for instance:
vncviewer.exe LT123456
I am a complete noob when it comes to javascripting and it is probably super simple. But I am stuck.
How do I send the variable from the button and how can I process the variable in the javascript?
This will become a button in a table with mulitple rows by the way. The variables will be parsed from a MySQL Database.
This is the script which now only starts the vncviewer.exe:
<script language="JavaScript" type="text/javascript">
MyObject = new ActiveXObject( "WScript.Shell" )
function RunVNCViewer() {
MyObject.Run("vncviewer.exe") ;
}
</script>
<button onclick="RunVNCViewer()">Run VNCViewer</button>
Thanks a whole heap!
Regards Mike