Thanks for the reply WittyKitty.
Nothing seems to work, I put him in his tray after a meal but he just jumps out again, he seems to wait until I'm out of the room to poo where he's not supposed to.
I've tried putting his poo in the litter tray and showing him but nothing seems to make a difference.
Sometimes he will use the tray and I give him lots of praise but it doesn't happen often enough.
This has been going on for a month now, I just don't know what to do.

He also treads in his poo sometimes and doesn't clean his foot.