VLC ActiveX and JavaScript

All you've ever wanted to know about the ActiveX, Mozilla plugins, the web interface and various PHP extensions
jagadish_ece
New Cone
New Cone
Posts: 4
Joined: 20 Jan 2006 08:46

VLC ActiveX and JavaScript

Postby jagadish_ece » 30 Sep 2006 10:08

Hi

I'm unable to call vlc activex object methods from javascript. when i try to call a vlc method from javascript, Internet Explorer says "Object doesn't support this property/method".

how to resolve this.


html code
---------------------------
<HTML>
<SCRIPT LANGUAGE="JAVASCRIPT">
function play()
{
document.vlc.pause();
}
</SCRIPT>
<BODY>
<OBJECT classid="clsid:E23FE9C6-778E-49D4-B537-38FCDE4887D8"
codebase="http://downloads.videolan.org/pub/video ... /axvlc.cab"
id="vlc" events="True">
<param name="Src" value="Die_Another_Day" />
<param name="ShowDisplay" value="True" />
<param name="AutoLoop" value="False" />
<param name="AutoPlay" value="TRUE" />
</OBJECT>

<H1>Hello</H1>
<input type=button vlaue=clickme onclick=play()></input>
</BODY>
</HTML>

pls help me
Jagadish

karlar
Blank Cone
Blank Cone
Posts: 73
Joined: 12 Jun 2006 12:25

Postby karlar » 02 Oct 2006 11:53

seems to work for me, getting no errors.
Just need to ask have you forgot to install the activex component ?

You can look for it in IE
tools -> programs -> manage add-ons -> add-ons currently loaded in Internet Explorer. Look for Videolan VLC activex ...

Yapadavaro
Blank Cone
Blank Cone
Posts: 22
Joined: 09 Nov 2006 09:49
Location: Annecy, France

Postby Yapadavaro » 09 Nov 2006 11:32

Hi jagadish_ece,

instead of :

Code: Select all

<input type=button vlaue=clickme onclick=play()></input>
try this :

Code: Select all

<input type='button' value='clickme' onclick='play();'>
and
instead of

Code: Select all

function play() { document.vlc.pause(); }
try that:

Code: Select all

function play() { if(document.vlc.Playing) { document.vlc.pause(); } else { document.vlc.play(); } }
Hope this help.
Yap.


Return to “Web and scripting”

Who is online

Users browsing this forum: No registered users and 32 guests