[Solved] Date minus one day in Item from iCalender

Hello,
I have a date in an item of iCalender in the format dd.mm.yy.

But I need the day before, that means in my calendar it is 6.3.22, but I need 5.3.22.

Is it possible to include a script in an item, or is it done by transformation? Is it possible to solve this with Blockly (I have installed the Date/Time-Addon).

No; difficult to imagine how that might work without creating an endless loop - update state, process to new value, update state, round we go.

Yes and yes, but kind of no.

Transformations allow you to process values moving from ‘here’ to ‘there’.
Typically, transforming a received value at a binding channel before putting it in an Item state.
Or often, transforming an Item state when passing it to a UI display.

There are no Blockly based transformation services, though.

Rules offer a different approach (and can be scripted with Blockly of course). You can process an Item value and then do whatever with the result, depending what you are trying to achieve. For a comparison or such, you might only need the result within the rule. If you need to display it, it must end up in an Item state. If you need to send it somewhere, most likely an Item command.

So “how” all rather depends on what you are trying to do …

Thank you for your reply.

I would like to be reminded to take out the rubbish on the day before the calendar entry.

But I have found a solution. In the profile of the item you can enter a time stamp offset, there I entered “-86400”. This way my calendar item has the date of the previous day.