Sitemap Graph Switch dont work

I wanted to create a Switch for different time charts on the sitemap, that work, but when i click on the switch for a different chart nothing happens.

Sitemap entry:

    Frame label="GraphT" icon="chart" {
        Switch item=gChartIntervall2 label=" " mappings=[0="1 Stunde", 1="4 Stunden", 2="12 Stunden", 3="1 Tag", 4="3 Tage", 5="1 Woche", 6="2 Wochen", 7="1 Monat", 8="2 Monat", 9="4 Monate", 10="1 Jahr"]
        Chart item=Temperatur period=h refresh=10000 visibility=[gChartIntervall2==0, gChartIntervall2=="Uninitialized"]
        Chart item=Temperatur period=4h refresh=10000 visibility=[gChartIntervall2==1]
        Chart item=Temperatur period=12h refresh=10000 visibility=[gChartIntervall2==2]
        Chart item=Temperatur period=D refresh=10000 visibility=[gChartIntervall2==3]
        Chart item=Temperatur period=3D refresh=10000 visibility=[gChartIntervall2==4]
        Chart item=Temperatur period=W refresh=10000 visibility=[gChartIntervall2==5]
        Chart item=Temperatur period=2W refresh=10000 visibility=[gChartIntervall2==6]
        Chart item=Temperatur period=M refresh=10000 visibility=[gChartIntervall2==7]
        Chart item=Temperatur period=2M refresh=10000 visibility=[gChartIntervall2==8]
        Chart item=Temperatur period=4M refresh=10000 visibility=[gChartIntervall2==9]
        Chart item=Temperatur period=Y refresh=10000 visibility=[gChartIntervall2==10]

.item entry:

Number gChartIntervall2 "Chart-Intervall"

The Charts without the Switch work.

Do you see your Item updating in events.log ?

Not connected, but needs to be
gChartIntervall2=="NULL"
in OH2

Yes, the items are updating and when i press the switch it updates too. As i said, a graph without the switch work just if i wanna change the duration nothing happens.
What do you mean with the second?

Does any chart display at all? ATM I don’t see any problem.
Probably unrelated:
Why is the number item named “gChartIntervall2”? The starting “g” is often used to name a Group. Why the number 2?

Would you show us the events.log for that please?

Your visibility selection includes the parameter
gChartIntervall2==“Uninitialized”
That is sensible in openHAB version 1, but in openHAB version 2 Items do not take the state Uninitialized at system startup, they take the state NULL.
Sometimes people find old posts and tutorials and do not spot the differences.