Steve
(the following assumes that this error clears when you turn the igntion off and back on - if it doesn't you may have a fault with the trans)
Ok so if you have tested the battery and it's ok, the most likely cause is your gear position switch.
I tried several remedies (and found my battery was knack'd along the way) only to have the problem recur.
Replaced the gear position switch and I have no problem now at all. Mine is an '01 model so if it lasts another 6 or 7 years I'll be happy. 
Mike
'00 D2 Td5 'Alice'
'03 V6 Freelander 'Phoebe'
'04 Td4 Freelander 'Harry'
Bookmarks