Rules don't react to simple item

Hi everybody,
I don’t know why I’m struggling so hard with openhab but currently I am trying to create some scenes.
In my Sitemap I created the following ITEM

Frame label="Szenen"{
    Switch item=Szene_Good_Morning label="Good Morning" icon="solarplant"
    }

Now my rule looks like

rule "Szene Good Morning"
when
    Item Szene_Good_Morning changed
then
    Light_EG_Wohnzimmer_UBoot.sendCommand(ON)
end

I’m sure that my command works as the following rule works perfectly fine:

rule "Trigger Test"
when
Time cron "0 * * * * ?"
then
    Light_EG_Wohnzimmer_UBoot.sendCommand(ON)
    createTimer(now.plusSeconds(5)) [| Light_EG_Wohnzimmer_UBoot.sendCommand(OFF) ]
end

It doesn’t matter if I say

    Item Szene_Good_Morning changed

or

    Item Szene_Good_Morning changed to ON

Why? Any hints?

Thanks in advance!

Did you create the item in an items file, e.g.:

Switch Szene_Good_Morning

Dan

Hey Dan, thank you very much, this did it.
I wasn’t aware that I had to declare the items in the .items-file as well (“Well, I could have thought about this”).

Nevertheless. Thanks again!

you’re very welcome

It’s not that you’re declaring them “as well” - you declare them in the items file. You may or may not then use those items in the sitemap.

I normally keep the icon and label definitions in the items file, so the sitemap can have a simple:

Switch item=Szene_Good_Morning