I’m trying to create a simple rule that based on door opening
The rule is triggered and the the first condition is to check if EveningNight event started
This return an error:
The name 'eveningNight' cannot be resolved to an item or type;
Thank you for your response
My rule is not based on astro event
The problem is with if condition that check the event state
rule "Door open light for 30 sec"
when
Item frontDoor received update OPEN
then
if(EveningNight.state == ON){
fl1_sw3_Entry2.sendCommand (ON)
createTimer(now.plusSeconds(30), [|
fl1_sw3_Entry2.sendCommand (OFF)
]
)
}
end
So where did you get the error message from? the rule doesn’t use eveningNight but EveningNight.
If you did a typo did you create the Item EveningNight as a Switch Item? Astro itself will only provide Channels, which then have to be linked to Items to get the current state of a channel. And there are some channels that can’t be linked to an Item at all, these are triggers only.