Despite the missing formatting, it looks weird. According to the Event Trigger documentation, I assume this automation triggers on any type of event (due to event_type being empty).
It’s not a matter of believe, either is does work or not. I guess you want the heating to go off, if the window is opened. Try this.
alias: Heizung aus bei Fenster auf.
description: ''
mode: single
trigger:
- platform: state
entity_id: binary_sensor.fenstersensor_arbeitszimmer_contact
to: open
condition: []
action:
- service: climate.set_hvac_mode
target:
entity_id: climate.heizung_arbeitszimmer
data:
hvac_mode: 'off'
PS: You should use the excellent visual automation editor from the UI.