INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Formating Lines of a Playlists  (Read 1297 times)

Soundcheck

  • Recent member
  • *
  • Posts: 15
Formating Lines of a Playlists
« on: March 26, 2017, 11:49:23 pm »

I want to Format a Playlist with the Expression language. By example: A field "Genre" contains the value "Cortina". I want to Highlight this line of the Playlist and assign a specific colour. Is that possible and can you describe how this is done?

Regards
Andreas
Logged

aviateur

  • World Citizen
  • ***
  • Posts: 159
Re: Formating Lines of a Playlists
« Reply #1 on: March 27, 2017, 10:57:07 am »

Andreas, Hi:

The following link is for the Expression Language and the related functions.
http://wiki.jriver.com/index.php/Expression_Language

I do not see any functions which will alter COLOR or HIGHLIGHT string values. In particular, look at the string manipulation section. The functions are limited. However, here is a suggestion based on my experience with the Expression Language. You could change the case of specific values in an effort to highlight the desired values. This does not address your specific question but it does give you some idea of how to manipulate text in a rudimentary way and give you a little experience with the Expression Language.

I have created an additional column in my view called 'Highlighting Test'. I initiated this by right-clicking the header for any column. I then selected 'Add Expression Column...'. I added the following expression: if(isequal([Genre], pop/, streetcorner,1), FixCase([Genre],3), [Genre])

This expression will change the case of the target field, in this case [Genre] to Uppercase when the [Genre] value is 'pop, streetcorner' (see images). Also note the use of the escape character (the forward slash). This allows me to treat the embedded comma in the [Genre] as part of the comparison value. Compare the values in the two columns to see the difference: 'Genre' and 'Highlighting Test'.

Another alternative might be to add a prefix to a [Genre] (remember, this is just for viewing purposes) such as 'Special' or '***'. You could then sort the column to separate your chosen values. These are just some thoughts for inspiration. Let me know if this helps.

Cheers,
Lawrence
Logged
Two Cows Walk Into a Bar ...

aviateur

  • World Citizen
  • ***
  • Posts: 159
Re: Formating Lines of a Playlists
« Reply #2 on: March 27, 2017, 11:13:53 am »

And one more thought, there are Smartlists to consider. Within these, you can select specific values for your chosen fields with 'Preset' rules for comparison criteria or you can create your own custom expression (Import/Export). The purpose is to create your desired results for your customized view. Let me know if you would like help with this.

Cheers,
Lawrence
Logged
Two Cows Walk Into a Bar ...

ferday

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 1732
Re: Formating Lines of a Playlists
« Reply #3 on: March 27, 2017, 05:22:49 pm »

Sure, you can color stuff.  This should get you started

https://yabb.jriver.com/interact/index.php/topic,107510.msg746544.html#msg746544
Logged

aviateur

  • World Citizen
  • ***
  • Posts: 159
Re: Formating Lines of a Playlists
« Reply #4 on: March 27, 2017, 06:29:40 pm »

Ferday, thanks for the coloring tip and the introduction to using HTML tags for this purpose. Everyday I learn something new: this was today's lesson.

Cheers,
Lawrence
Logged
Two Cows Walk Into a Bar ...

aviateur

  • World Citizen
  • ***
  • Posts: 159
Re: Formating Lines of a Playlists
« Reply #5 on: March 28, 2017, 12:52:05 am »

Andreas, Hi:

This is an update to my original post. From what I learned from Ferday's post above, I implemented color using HTML font properties along with the UPPERCASE [Genre] text in the expression column called 'Highlighting Text'. You originally asked for a description of how to accomplish this. This should help. So, you now have Ferday's reference for employing color in a CUSTOM field and my example for employing color in an expression column (see images). The HTML font properties available in the Expression Language are documented toward the end of the link I originally cited:
http://wiki.jriver.com/index.php/Expression_Language

Cheers,
Lawrence
Logged
Two Cows Walk Into a Bar ...
Pages: [1]   Go Up