Barry: There are a couple of things you can do.
First, if you can turn off the 2-way response at the receiver, it will help when teaching the commands to the MX-500. If your model is one that can't be turned off, take the 2-way remote and the MX-500 into a different room (from where the receiver is located.) The idea here is that the receiver's signal response is interferring with the signals you need to learn.
The other thing is to go to Daniel's Tips and Tricks section.
[Link: remotecentral.com] This area will help the teaching process quite a bit.
Lastly, if your budget can allow for it, use a One-For-All Cinema 7 (or it's equivalent for around $25 or so.)
The C7 can generate some generic Sony receiver codes that may help control your gear better. (Also, I have discovered that sometimes, the original Sony remotes don't send as "learnable" of a signal as the Cinema 7. For eg., plain old volume up & down seems to work better learned from the C7 than it does from the original Sony remote. At least in my experience.)
Good Luck!