Hi,
I have a question about an inserted OBJECT-element of Windows
MediaPlayer and get acces to this object during an event.
I put the next OBJECT in de main.js as string, and add this with
appendElement:
---- code ----
var playobj = "<object classId='clsid:6bf52a52-394a-11d3-
b153-00c04f79faa6' name='objWmp' id='objWmp'>";
playobj += "<param name='AutoStart' value='true' />";
playobj += "<param name='url' value='xxx'/>";
playobj += "</object>";
function view_onOpen() {
// Add the player object
ret = view.appendElement(playobj);
}
---- code ----
This works. But now I want access to the object of 'objWmp'?
I have tried the next options:
--- code ---
function btnPlayStopclick() {
if (bMediaPlayerEnabled) {
var obj = view.children('objWmp');
obj.controls.stop();
}
}
--- code ---
But the gadet will comes with an exception of incorrect object
function or method. But "controls.stop();" is the correct function to
stop playing the WMP object.
I think that 'obj' variable the object is of the appendElement during
previous event onview_load(). How can I access to the OBJECT within
this object?
Thanks you.