There could be one or more than one problem here. I would take this to a pro. The sunroof is not that complex after you learn it. Learning it is the key though. I would stay away if I did not know them or at least did not have the manual to repair. You can do damage to the inner sleeve (conduit) and then you have had a really bad day.
There are over 25 steps in the adjustment process. Many people do not know this. I had a tech who had worked on Mercedes for longer than I have been alive. One day he had a sunroof that wouldn't work correclty after he'd repaired it. I went and correctly adjusted it. It worked. Then I showed him the book and where to find the information.
The point is you need professional help, but make sure they know how to correctly find the problem and repair it.
ASE CERTIFIED MASTER AUTO TECHNICIAN
MERCEDES SPECIALIST 8 YRS
PARTNER IN MERCEDESSHOP.COM
OWNER OF MB AUTOWERKS .COM