RELOC.BA by James Yi will move a machine language program to a new location. First execute LOADM on the program to be moved (it may be in memory but unsaved) to display its TOP,END,EXE addresses. Next run RELOC, enter the programs name and its TOP,END,EXE addresses. If there is a data table that is not to be interpreted as code press "y" at the data table prompt and enter its starting and ending addresses, RELOC will skip this area and will not adjust it. If you don't know if there is a data table then just go with "n" and you will have, perhaps, a 80% chance of success. Next enter the address to which the program is to be moved. Choose the Auto mode if you don't have a disassembed file with you and don't know what to answer to each prompt in the Manual mode. If run in the Auto mode RELOC checks to see if any three-byte-long instruction points to an address within the the programs range. If it does then RELOC pokes in new values (already adjusted for the new location). If the Auto mode didn't adjust all the addresses and move the program successfully you can try the Manual mode. RELOC will pause at each instruction that is 3 bytes long. The ENTER key will adjust its contents, any other key will leave it unchanged and continue to the next instruction. One would probably need a source code to do this but in most cases the Auto mode will work. If neither mode has any success in relocating a machine language program then the problem is probably one of the following: 1) There is an indirect addressing scheme where the HL register is loaded in from a data table (RELOC skips the data table) with the resulting contents of HL pointing to a new address within the programs range. 2) A register pair such as H/L is loaded seperately and therefore is not recognized as a three-byte-instruction by RELOC. 3) The contents of a three-byte-instruction such as C30000 is poked in later by a routine so that when RELOC sees it, it might read JMP 0 and goes undetected but after the program is executed its contents change and might read JMP 61000. As RELOC goes through and checks the program it displays each line as follows: The codes original location, the new location in parenthesis, a mnemonic for the code or a number if it is data, its contents if any and the changed contents in parenthesis (if it was changed). After RELOC is done press "y" to save the result, or any other key to cancel it. Be sure to set the new HIMEM with the CLEAR statement.