Gearbox fault and restricted performance

I had a gearbox fault message and a restricted performance message with my 2000 xk8. I took it to shop and they said it needed a new transmission due to code 0706. They put in new trans and 2 days later it’s doing the same thing. I’m suspecting I never needed the new transmission now. Getting no help from shop. Any advice? Car has 102k miles and I’m original owner. Any thoughts would be most appreciated!

That code is for the ‘Transmission range sensor switch’ basically it tells the trans when to change gears. If that sensor was carried over from the original trans that could be the problem, disclaimer I’m not sure where that switch resides in the trans so could be a red herring.
If the shop will not co-operate then it sounds like you might be going to the small claims court?
Depends where you live of course. This would normally be a last line of attack.

I would be annoyed if it turned out to be a simple mis-adjustment of a cable or similar. Certainly hope the shop did some checking before chucking in a new transmission.

If there is a mechanical connection between the gearshift range selector and the gearbox, suspect the engine and gearbox mounts are worn out.
The engine and gearbox sit lower as the mounts compress, which in turn pulls on the selector linkage.
Usually what happens is when you accelerate it pulls the gearbox selection out of the currently selected range, so a fault is recorded.

Connection is cable, plenty of movement possible without issue there.
Cable however, does need to be correctly adjusted.

Sorry. I had the wrong code. The tech said it gave off a P 0733 code. An issue with the 3rd gear.