getmusicbee.com
Support => Questions => Topic started by: Alumni on August 08, 2016, 10:25:32 AM
-
Maybe someone with more syntax experience can help me out. I'm trying to create the following virtual tag - display the contents of a custom tag, unless the tag's value is x, in which case nothing will be displayed.
-
I think this should work:
$If($IsMatch(<Custom1>,"x"),,<Custom1>)
And you could add something that might make it more solid for some uses:
Suppose the 'x' from your example is 'jazz'.
And you want to have your virtual tag shown empty only when the custom tag contains only and exactly 'jazz', but you do want to display the contents of the custom tag if it contains 'jazz rock' or 'acid jazz'.
Then you could use:
$If($IsMatch(<Custom1>,"^jazz$"),,<Custom1>)
-
Thanks hiccup, that did the trick. Do you know if it's also possible to use $IsMatch with more than one expression? For instance, if custom tag 1 has value x or y, display nothing.
-
Yes, than it would be something like:
$If($Or($IsMatch(<Custom1>,"x")=T,$IsMatch(<Custom1>,"y")=T),,<Custom1>)
(or you can replace "x" with "^x$", see the edit I made to my earlier reply)
-
Great thanks, that will do nicely.