# Flash, javascript & HTML

**URL:** <https://forum.kirupa.com/t/flash-javascript-html/313768>\
**Category:** programming\
**Created:** [September 9, 2010, 7:13am UTC](https://forum.kirupa.com/t/flash-javascript-html/313768 "2010-09-09T07:13:16Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![mohiniraj](https://avatars.discourse-cdn.com/v4/letter/m/67e7ee/32.png) [@mohiniraj](https://forum.kirupa.com/u/mohiniraj)\
**Post date:** [September 9, 2010, 7:13am UTC](https://forum.kirupa.com/t/flash-javascript-html/313768/1 "2010-09-09T07:13:16Z")

</div>

Hello,

I have one swf which at the end passess some variables through fscommand to HTML and HTML reads those with the help of Actionscript 2.0 Javascript & VB Script. It also has embed Tag to embed flash in HTML.

I have published my swf file through HTML with fscommand settings.

My problem is the VB script is not supported on my clients PC. my code is;

```auto
 
<script language="JavaScript">
<!--
var isInternetExplorer = navigator.appName.indexOf("Microsoft") != -1;
// Handle all the FSCommand messages in a Flash movie.
function test_DoFSCommand(command, args)
{
    var testObj = isInternetExplorer ? document.all.test : document.test;
 if(command=="calltype")
 {

 document.FormX.message.value = args;
 top.banner.document.getElementById('hdVisitedTime').value = args ;
}

if (navigator.appName && navigator.appName.indexOf("Microsoft") != -1 && navigator.userAgent.indexOf("Windows") != -1 && navigator.userAgent.indexOf("Windows 3.1") == -1) {
 document.write('<script language=\"VBScript\"\>
');
 document.write('On Error Resume Next
');
 document.write('Sub test_FSCommand(ByVal command, ByVal args)
');
 document.write('Call test_DoFSCommand(command, args)
');
 document.write('End Sub
');
 document.write('</script\>
');
}
 
</script>

```

my question is, Is there any option to read flash variables in HTML without this script and Actionscript 3.0?

Thanks,  
Mohiniraj
