Probably your best bet is to get an inexpensive programmable One-for-All and then use the JP1 tool set to create a code on your PC and load into the remote (or codes -- to get 50 command keys you may need to ceate more than one "device") . Go check out the JP1 forum at
www.hifi-remote.com to get an idea of what tools are available.