Markers in Media Player 7 ?

T

Trevor Daniel

Hello,

I have been trying to make an embedded Windows Media Player jump to a fro between markers in a streamed file.

I have found that if i embed the 6.4 player, then my javascript works perfectly. If i embed the verion 7 player, the javascript says there are no markers in the file. I am using the following javascript to access the markers.

Any help ideas would be appreciated on what could be the cause and solution.

Thanks

Trevor

function seekToMarker(iWhichMarker){
if ((navigator.userAgent.indexOf("IE") > -1) && (navigator.platform == "Win32")) {
// This is an error handler. If the user tries to scan to a marker which doesn't
// exist, the player will pop an error message. By using this code, we
// can create a custom error message.
if (iWhichMarker <= document.Player.MarkerCount) {
// This resets the current marker in the file.
document.Player.CurrentMarker = iWhichMarker;
document.Player.Play();
} else {
alert("This Marker doesn't exist. (No Markers were found!)");
}
} else {
if (iWhichMarker <= document.Player.GetMarkerCount()) {
document.Player.SetCurrentMarker(iWhichMarker);
document.Player.Play();
} else {
alert("This Marker doesn't exist. (Markers were found!)");
}

}
}
</SCRIPT>

And the code used to emded the object is:

<OBJECT id="Player" style="Z-INDEX: 112; LEFT: 16px; WIDTH: 320px; POSITION: absolute; TOP: 216px; HEIGHT: 305px"
classid="clsid:6BF52A52-394A-11D3-B153-00C04F79FAA6" VIEWASTEXT><PARAM NAME="URL" VALUE="Home_To_Work.asx"><PARAM NAME="rate" VALUE="1"><PARAM NAME="balance" VALUE="0"><PARAM NAME="currentPosition" VALUE="0"><PARAM NAME="defaultFrame" VALUE=""><PARAM NAME="playCount" VALUE="1"><PARAM NAME="autoStart" VALUE="-1"><PARAM NAME="currentMarker" VALUE="0"><PARAM NAME="invokeURLs" VALUE="-1"><PARAM NAME="baseURL" VALUE=""><PARAM NAME="volume" VALUE="50"><PARAM NAME="mute" VALUE="0"><PARAM NAME="uiMode" VALUE="full"><PARAM NAME="stretchToFit" VALUE="0"><PARAM NAME="windowlessVideo" VALUE="0"><PARAM NAME="enabled" VALUE="-1"><PARAM NAME="enableContextMenu" VALUE="-1"><PARAM NAME="fullScreen" VALUE="0"><PARAM NAME="SAMIStyle" VALUE=""><PARAM NAME="SAMILang" VALUE=""><PARAM NAME="SAMIFilename" VALUE=""><PARAM NAME="captioningID" VALUE=""><PARAM NAME="enableErrorDialogs" VALUE="0"><PARAM NAME="_cx" VALUE="8467"><PARAM NAME="_cy" VALUE="8070"></OBJECT>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,764
Messages
2,569,565
Members
45,041
Latest member
RomeoFarnh

Latest Threads

Top