Click here to Skip to main content
15,897,095 members
Articles / Programming Languages / XML

WMP Playlist Fix

Rate me:
Please Sign up or sign in to vote.
4.80/5 (2 votes)
6 Dec 2013CPOL6 min read 20.5K   546   5  
The goal is to clean-up double entries in Windows Media Player playlists because the player doesn’t do that itself. For that, a WPL class has been written, and a program that uses that class.
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
	<head>
		<title>About WMPPlayListFix</title>
    <style type="text/css">
    body 
    {
	    font-family: Verdana, Geneva, sans-serif;
	    margin: 2px;
      background-color: #AAAAAA;
    }

    h1,h2 
    {
	    margin: 4px;
      color:Green;
    }
    h1
    {
      font-size: 12pt;
    }
    h2
    {
      font-size: 11pt;
    }

    p 
    {
	    margin: 2px;
	    font-size: 9pt;
    }
    ul
    {
      font-size:9pt;
    }
    .extreme 
    {
	    font-weight:bold;
	    font-size:medium;
	    font-variant:normal;/*	padding: 0px;*/
	    color:Black;
    }
    </style>
	</head>
	<body>
  <h1>About WMPPlayListFix</h1>
  <p>This tool is able to fix a few problems that Windows Media Player (WMP) doesn't do, mainly 
  removing double entries from a playlist.</p>
  <p>What is the problem:</p>
  <ul>
    <li>WMP doesn't check if a song is already in a playlist and will add doubles. Those doubles
    can only be manually removed, which is very labourious. This application can check and remove 
    doubles using one of three methods:<br /></li>
      <ul>
        <li>Check on filename: here the fileame part of the path to the music file is used to compare for doubles</li>
        <li>Check on location: here the whole path of the music file is used to look for doubles. 
        this is a good method to remove doubles that are caused by accidentally adding the same ablum multiple times.</li>
        <li>Check n tracktitle: this is a slow process (because each media file has to be opened) but works very good 
        to remove doubles that occur because the same song is preformed by multiple artists and/or is present on multiple albums.  
        Only one (this first one in te list) remains after usig this method.<br /><br /></li>
      </ul>
    <li>WMP doesn't check if media files still exists when a playlist is opened, only when it tries to play the song 
    the player stops and presents an error. This application  removes any playlist entries that points to a file
    that doesn't exists anymore.<br /></li>
    <li>When synchronizing a playlist to a mobile device that is smaller than the contents of the playlist you want to
    shuffle the music to that device. Despite WMP having a shuffle function it still writes the playlist to
    the device in the sequence it is in the playlist (alphebetical). This application can shuffle a playlist
    so WMP synchronizes a shuffled playlist to the device. There are other ways to do it's, but this is easier.</li>
  </ul>  	

  <h2>Using the software</h2>
  <p>First of all, you need to have Microsoft Windows Media Player installed, a version newer then version 9.</p>
  <p>When the program starts for the first time the application tries to find the WMP playlist folder. 
  If it has located this folder then the File Selection box is filled with the playlists it find in that folder, 
  if there are more then 15 files a selection is placed in the list. 
  The folder selection is set to the WMP playlist folder</p>
  <p></p>
   

  <h2>Limitation</h2>
  <ul>
  <li>The program works best with MP3 music files.</li>
  <li>The program all works properly if the playlist that it works on is in the WMP playlist folder. 
  Do not copy playlists to other folders and work on them there, that doesn't work because of the way
  Micorosoft stores the link to the media file in the playlist.</li> 
	</ul>
  </body>
</html>

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Software Developer (Senior)
South Africa South Africa
Started in 1988 programming in Pascal, making a 68000 emulator on a DOS platform. Then from Pascal to Clipper, to C++ and now using C#. I've been programming for all walks of businesses; opticians, opthomologist, carbage collectors, reinforcement steel producers, retail chains, and more.
I'm now travelling through Africa with a home-build expedition truck.

Comments and Discussions