MotoWilliams

dot this & dot that

  Home  |   Contact  |   Syndication    |   Login
  7 Posts | 0 Stories | 8 Comments | 4 Trackbacks

News

The views expressed on this weblog are mine and do not necessarily reflect the views of my employer.

All postings are provided "AS IS" with no warranties, and confer no rights.

Archives

Post Categories

A+ Blogs

Biztalk / Windows WF

PodCasts

WebSphere MQ

Monday, August 08, 2005 #

Windows Media Center has to have the Album Artist tag set in order to show up in the My Music module of Windows Media Center. Since this is driven by the Windows Media Player library those tags need to set there. Unfortunately for me almost none of those tags were set in my library so it was time for some scripting:

Dim Artist
Dim AlbumArtist
Set objPlayer = CreateObject("WMPlayer.OCX" )
Set objMediaCollection = objPlayer.MediaCollection
Set colSongList = objMediaCollection.getByAttribute("MediaType", "Audio")
For i = 0 to colSongList.Count - 1
Set objSong = colSongList.Item(i)
Artist = objSong.getItemInfo("Artist")
AlbumArtist = objSong.getItemInfo("WM/AlbumArtist")
if Artist <> AlbumArtist then
wscript.echo objSong.Name
Wscript.Echo Artist & "=" & AlbumArtist
wscript.echo
objSong.setItemInfo "WM/AlbumArtist", Artist
end if
Next

I've been using SyncBackSE for quite a while now and I'm almost embarrassed on how much I love this little thing. I use it to keep my music in sync between my Media Center PC and my two portable USB hard drives. I don't have too much music , only about 7600 songs, but it is such a pain to remember which tags have been updated on which drive when I go into my tag clean up frenzies which is a requirement of Media Center to have all your music diplayed in the My Music section. I also use it to keep my work laptop's data files and my local source code snippets backed up to my home drive at work. Saves me tons of time on my 4 to 5 month repaving schedule!

Now it looks like Microsoft has a similar tool on the way with SyncToy. Although I don't understand what they were thinking naming a function 'echo'...