Share via


Windows Media Player 11 SDK Player.newPlaylist 

Windows Media Player SDK banner art

Previous Next

Player.newPlaylist

The newPlaylist method creates a new Playlist object.

Syntax

  

Parameters

name

String containing the name of the new playlist.

URL

String containing the URL of the Windows Media metafile playlist to create the Playlist object with.

Return Values

This method returns a Playlist object.

Remarks

If the URL parameter is set to null or "" (empty string), an empty Playlist object will be created. If the name parameter is set to "", the name in the metafile is used.

The new playlist created with this method is not added to the library. To add a new playlist to the library, use PlaylistCollection**.importPlaylist** or PlaylistCollection**.newPlaylist**. Any leading or trailing spaces in the playlist name are automatically removed when it is added to the library.

Because the library allows multiple playlists with the same name, you may want to check for the presence of a playlist with a given name before adding a new one.

Requirements

Version: Windows Media Player 9 Series or later.

Library: Use wmp.dll.

See Also

Previous Next