This question has been asked many times on these forums, and unfortunately the answer is no. As mentioned, your only option is to use a VNC server but it would be very slow and mostly unusable. Laptops and all-in-ones like iMacs are not designed to have a video input to be used as an external monitor.