I ran across this tidbit on RangeRovers.net and it has saved me twice.  First my sunroof wouldn’t sit flat causing water ingress and excess air noise, this solved that.  Then it wouldn’t one touch close this can also fix that.

To Fix: Hold the sunroof tilt button until you hear a the motors click, let go of the sunroof tilt button then press and hold the sunroof tilt button again and it will continue to set itself.

Check out some of the later instructions around post 14 or so.

http://www.rangerovers.net/forum/6-range-rover-mark-iii-l322/33490-express-close-sunroof-not-working.html