Hi all,
I'm looking to create a rule to hide a panel when the current month is not equal to September through December.
I tried calculating the dates and then hiding the panel for dates greater than or equal to 01-01-2019 and less than 01-09-2019. However I didn't quite manage that and I realised this rule would have to be revised come 2020.
So I thought I could go with the runtime function: contains(). The idea is to hide the panel if the current date does not contain "september" etc.
I used the following rule:
!contains(txt_CurrentDate, "september") && !contains(txt_CurrentDate, "oktober") && !contains(txt_CurrentDate, "november") && !contains(txt_CurrentDate, "december") |
txt_CurrentDate is a calculated value control that references the CurrentDate, saved as a string.
I checked the date format, for example today would be: woensdag 24 april 2019 00:00:00 (date culture NL-nl).
Also, I tried to test the above rule, by using the function dateAddMonths().
I can't get this to work. "woensdag 24 oktober 2019 00:00:00", for example, still hides the panel.
What am I doing wrong? Thanks!