Page 1 of 1

Season Year {sy} in parentheses () instead of brackets []

Posted: 17 Jan 2022, 08:39
by rednoah
{sy} is a List<Integer> object, so you can use Collection.joining(delimiter, prefix and suffix) for custom formatting.

e.g.

Format: Select all

{ sy.joining('-', '(', ')') }

Code: Select all

(2002-2003)

Re: Season Year {sy} in parentheses () instead of brackets []

Posted: 26 Mar 2022, 09:00
by Orthos
Hello!

When I use {sy} I get brackets around the season year. e.g. [2002] But I want parentheses instead. And I only want the year of each season. e.g. .../Season 01 (2010)/... ; .../Season 02 (2011)/... ; .../Season 03 (2011)/...

How can I do that? Can anyone help, please! :)

Regards,
Marc

Re: Season Year {sy} in parentheses () instead of brackets []

Posted: 26 Mar 2022, 09:01
by rednoah
Orthos wrote: 26 Mar 2022, 09:00 When I use {sy} I get brackets around the season year. e.g. [2002] But I want parentheses instead.
e.g. season years:

Code: Select all

{ sy.joining('-', '(', ')') }
e.g. season start year:

Code: Select all

({ sy.first() })

Re: Season Year {sy} in parentheses () instead of brackets []

Posted: 26 Mar 2022, 09:13
by Orthos
Fast response (#meepmeep)! Wow!! Thanks!!! :)

{ sy.joining('-', '(', ')') } works, but I thought it will show the whole airdate years e.g. (2002-2003) and not only e.g. (2002)