Share via


Player6.GetMediaParameterName (deprecated)

Windows Media Player SDK banner art

This page documents a feature of the Windows Media Player 6.4 ActiveX control. We recommend that you migrate your content to use the Windows Media Player 9 Series ActiveX control. For more information about the Windows Media Player 9 Series ActiveX control, see the Windows Media Player 9 Series SDK.

This method retrieves the name of the specified parameter for an indexed Windows Media metafile entry.

Syntax

MediaPlayer.GetMediaParameterName(lEntryNum, lParamNum)

Parameters

*  lEntryNum*

Long value indicating the index number of an ENTRY element in the Windows Media metafile. 

*  lParamNum*

Long value indicating the index number of a PARAM element within the specified ENTRY element. 

Return Value

Returns a String value representing the NAME attribute of the specified PARAM element. This method returns a null value if lEntryNum is outside the range of the EntryCount property, or if no PARAM element numbered lParamNum exists within the specified ENTRY element.

Remarks

The PARAM element allows you to place additional information into a Windows Media metafile, which the Windows Media Player control can then access through scripting. For example, you could insert the names of the producers of the media files inside the Windows Media metafile and display them in HTML somewhere near the Windows Media Player window.

Use this method to determine the names of the PARAM elements within a Windows Media metafile ENTRY element. You can then call the GetMediaParameter method to determine the value associated with each name.

The first ENTRY element in a Windows Media metafile has a lEntryNum index number of 1. Index number 0 is reserved for child elements of the Windows Media metafile tag, which applies to information valid for the entire show.

An example Windows Media metafile might look like the following.

<ASX VERSION="3.0">
    <TITLE>The Title of the Show<TITLE>
<ENTRY>    
    <REF HREF="YourMediaFilename.asf" />
    <TITLE>The Title of the Track</TITLE>
    <PARAM NAME="Producer" VALUE="Jane D.">
</ENTRY>
</ASX>

To retrieve the name of the first PARAM element, call the method as follows.

MediaPlayer.GetMediaParameterName( 1, 1 );

This method call would return the string "Producer".

Note   This scripting method is only available for Windows Media Player version 6.01 and later. The standard installation of Microsoft Internet Explorer 5 includes a compatible version of Windows Media Player.

Requirements

Version: Windows Media Player version 6.4.

Library: Use msdxm.ocx.

Platform: Windows 98 Second Edition or higher.

See Also