Here we go again... In your first post you clearly defined the ranges as contiguous (xxxxxM1 - xxxxxM400) then you changed it to xxxxxm1 – xxxxxm60 and now again something different. Are you going to change your story yet again?
If you don't have easy contiguous ranges that can be determined with IF and/or CASE statements then maybe you should setup an INI file to translate.
You are nesting IF conditions that don't make any sense. for example:
IF $LOC >= "M74" AND $LOC <= "M88"
IF $LOC >= "M130" AND $LOC <= "M144"
the first IF <= "M88" contradicts the second >= M130".
You are also trying to do > and < comparison on strings which is fraught with problems. Better to leave the "M" out and convert the rest with VAL().
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.