Help - Search - Members - Calendar
Full Version: Dynamic Playlists
Hydrogenaudio Forums > Hosted Forums > foobar2000 > Support - (fb2k)
randomcake
Sorry to keep posting what must be some really stupid questions, I've been trying to figure this one out for ages! I've read all the forum posts I can find that are related and I *think* that to create dynamic playlists one option is to create a custom 'view' for Album List, is this correct?

Anyway, I've tried writing some code to test the value of %rating% and have this:

CODE
$if2([%rating%>3,[%album artist% - ]['['%date%']' ]%album%|[[%discnumber%.]%tracknumber%. ][%track artist% - ]%title%)


Which doesn't work... Can anyone point out why? I'm trying to get the view to only show tracks with a rating of 3 or more.

This isn't how I'd idealy do it so if anyone can tell me of a better way I'd be very greatful!

Sorry for being a pain and thanks for being helpful smile.gif

RandomCake
Frank Bicking
I assume you use 0.9.5 because it was not possible to create autoplaylists from the Album List before.

First of all, regarding your code, you should use $if instead of $if2 in this case. Second, apart from the unclosed bracket in front of %rating%, the problem is that there is no ">" operator. Use $greater(%rating%,3) for comparisons.

QUOTE
I *think* that to create dynamic playlists one option is to create a custom 'view' for Album List, is this correct?

You can do it this way, but it's too complicated as you would have to edit the view each time you want to apply a different rule when creating a new autoplaylist.

I'd recommend to enter a query into the Album List's filter field instead, for example:

CODE
rating GREATER 3

Once the Album List is filtered, create an autoplaylist from the "All Music" item, or the desired subitem.
randomcake
Thank you so much Frank! I've got it all working now! biggrin.gif

Maybe something on Dynamic Playlists should be added to the wiki or something, once I knew what I was doing it was easy, how do I go about being able to write in the Wiki (set up an account and just tried to edit a page in the Foobar2000 section and it's not happening!)


Removed unnecessary fullquote.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2008 Invision Power Services, Inc.