Screen goes black as soon as I connect it with my HDMI cable?

Eg
2

I have a laptop and want to connect it to my monitor with an HDMI cable. As soon as I connect the laptop with the cable, the laptop turns black (but continues to run) and does not connect to the monitor. Otherwise that was not the case. Does anyone have a solution for this problem?

Fo

Windows key and P

Duplicate (second)

Eg

Thanks it worked