i only want to have the shadow of the rope showing, but as you can see somehow shadows are being cast onto the layers which doesn't look good. I'm pretty new to blender and tried to mess with the lamp settings but can't get it to work for the life of me. it seems to look okay in rendered view (with the layers only showing the shadows ofcourse) but when i render it always turns out like that no matter what i do.
You can turn the wall into a shadow catcher by looking at the Cycles Settings in the Object Panel.
In this case, select the wall object and enable Shadow Catcher. You might have to adjust the diffuse color of the wall to white in order to make the wall completely transparent.