There are about three causes as to why you would get such a thing as you describe.
1. If the laptop has the intel onboard HD graphics solution the driver can often glitch or become corrupted. The driver should be uninstalled and the system should be rebooted then re install the intel HD driver.
If it fails, then you need to look at if the internal video cable from the laptop board to the screen is loose or damaged. It is quiet common in aged or old laptops as the cable passes through or near the hinges that allow you to close the screen flat onto the keyboard or base of the laptop. It often takes quiet a bit of disassemble of the laptop it`s self to get to the cable though.
Replacement cables can be found on ebay.
The last thing is replacement of the screen, but the other options should be done first as it is cheaper on the pocket than a new screen and could be the cause of the yellow line.